Slot machine payouts are calculated using a combination of random number generators (RNGs) and predetermined payout percentages. The RNG determines the outcome of each spin, ensuring that results are random and unpredictable. Each slot machine is programmed with a specific payout percentage, known as the Return to Player (RTP), which indicates the average amount that players can expect to win back over time relative to their total bets. This percentage is determined through extensive mathematical analysis and game testing.