Lotto Number Generator: Fixed and Excluded Numbers + Stats

PublishedToolLotto Number Generator & Filter

Contents
  1. Why handling fixed and excluded numbers by hand gets tedious
  2. How to build a combination with fixed and excluded numbers
  3. Stats you can use as a reference when reviewing a combination
  4. Wrapping up
  5. Frequently Asked Questions

When you pick Lotto 6/45 numbers, sometimes a fully automatic pick isn't what you want. You'd rather guarantee that a few numbers show up and that certain numbers stay out entirely. But keeping fixed numbers and excluded numbers straight by hand while filling the remaining slots means duplicate checks and extra math. This post covers how to build combinations that respect fixed and excluded numbers, plus the stats you can use as a reference when you look at a combination — odd/even ratio, total sum, and more.

Summary ① Once you set fixed numbers (numbers that must be included) and excluded numbers (numbers you want out), the remaining slots can only be filled at random from what's left in the candidate pool. ② Odd/even ratio, number total, and consecutive numbers are stats you can use as a reference when reviewing a generated combination. ③ With our Lotto Number Generator & Filter, you can enter fixed and excluded numbers and see combinations along with these stats right away.

Why handling fixed and excluded numbers by hand gets tedious

A fully random automatic pick is easy, but the story changes when you want certain numbers guaranteed in (fixed numbers), certain numbers kept out (excluded numbers), and only the rest filled at random. To honor both at once and still fill 6 slots with no duplicates, you need a procedure: build a list of candidate numbers first, then draw from it at random. Repeating that by hand every week isn't easy.

How to build a combination with fixed and excluded numbers

The procedure for drawing numbers with fixed and excluded numbers in play breaks down like this.

  1. Build a candidate pool from 1 to 45 with the excluded numbers removed. For example, if you set 5 excluded numbers, the pool is 45 minus 5, which is 40.
  2. Fixed numbers are already locked in, so leave them alone and fill only the slots left over — 6 minus the number of fixed numbers — at random from the candidate pool. If you set 2 fixed numbers, you draw the remaining 4 slots at random from those 40 candidates.
  3. Combine the fixed numbers with the newly drawn numbers and sort them in ascending order to finish the final 6-number combination.

Here's that process in code.

function generateLottoCombination(fixedNumbers, excludeNumbers) {
  const fixedSet = new Set(fixedNumbers);
  const excludeSet = new Set(excludeNumbers);

  // 1. Build the pool of valid candidate numbers
  const candidatePool = [];
  for (let i = 1; i <= 45; i++) {
    if (!fixedSet.has(i) && !excludeSet.has(i)) {
      candidatePool.push(i);
    }
  }

  // 2. Draw as many as needed at random
  const neededCount = 6 - fixedSet.size;
  if (candidatePool.length < neededCount) {
    throw new Error("유효한 후보 숫자가 부족합니다.");
  }

  const selected = Array.from(fixedSet);
  while (selected.length < 6) {
    const randomIndex = Math.floor(Math.random() * candidatePool.length);
    const num = candidatePool.splice(randomIndex, 1)[0];
    selected.push(num);
  }

  // Sort ascending
  return selected.sort((a, b) => a - b);
}

Note If you set so many fixed and excluded numbers that the candidate pool can't fill 6 slots, the code above throws an error and no numbers are generated. In that case, reduce the excluded numbers or adjust how many fixed numbers you use.

You don't have to run code or hand-sift a candidate pool — check it with our tool.

Lotto Number Generator & Filter

Set your own fixed and excluded numbers, then generate free 6/45 lotto number combinations along with stats like odd/even ratio and sum.

Enter your fixed numbers (up to 5) and the numbers to exclude, choose how many games to generate (1, 3, or 5), and press Generate Numbers. You'll see each combination with its number-range colors along with the stats.

Stats you can use as a reference when reviewing a combination

After the numbers are drawn, you can look over the combination using the metrics below as a reference.

  • Number total: the sum of all 6 numbers. Combinations skewed very low (say, 1+2+3+4+5+6=21) or very high (say, 40+41+42+43+44+45=255) tend to show up rarely among actual winning numbers.
  • Odd/even ratio: how many of the 6 numbers are odd versus even. Combinations where all 6 are odd or all 6 are even (6:0, 0:6) are relatively rarer than a 3:3 or 2:4 split.
  • Consecutive numbers: a flag that reads "yes" if even one pair of numbers runs back to back, like 12-13. You don't need three in a row — just two next to each other triggers it.

Wrapping up

Drawing numbers with fixed and excluded numbers is a way to force the numbers you want in or out into the combination. The number of ways to choose 6 out of 45 is 8,145,060, and whatever combination you pick, the odds of winning are the same.

That said, avoiding combinations whose odd/even ratio or total is heavily skewed to one side — or patterns other people also pick often — can help reduce the cases where you'd split the prize if you win. Instead of sifting a candidate pool yourself, enter your fixed and excluded numbers in the tool below and see the combination and stats right away.

Lotto Number Generator & Filter

Set your own fixed and excluded numbers, then generate free 6/45 lotto number combinations along with stats like odd/even ratio and sum.

Frequently Asked Questions

How many fixed and excluded numbers can I set?

You can set up to 5 fixed numbers, and the remaining slots are filled at random from the candidate pool after excluded numbers are removed. There's no separate cap on how many excluded numbers you can use, but as the combined total of fixed and excluded numbers grows, fewer candidate numbers are left to fill the slots.

How many games can I generate at once?

You can pick 1, 3, or 5 games and generate them all at once. Each generated combination shows its number-range colors along with stats like odd/even ratio and total.

What do the odd/even ratio and total sum actually tell me?

Past Lotto winning numbers are known to cluster around odd/even ratios of 3:3 or 2:4/4:2, and around total sums between 130 and 180. The tool shows whether a generated combination falls in these ranges so you can use it as a reference.

This article was adapted from our Korean original. Read the Korean original

Related articles

  1. Open Graph Image Cache: Why Share Previews Don't UpdateShare previews on Facebook or KakaoTalk still show the old og:image because platforms cache it. See how to refresh each platform's cache or bypass it.
  2. Pinterest Image Ratio 2:3: Why Instagram Sizes Get CroppedPinterest's 2:3 ratio vs Instagram's 4:5 and 1:1: see how much padding or cropping an off-ratio image gets, and how to check the math yourself.
  3. Why Cropping a Profile Photo at High Zoom Looks BlurrySee why zooming in and cropping a profile picture lowers image quality, and how to check a photo's pixel size to predict it before you upload.
  4. Blog reading time calculation: why sites show different minutesBlog reading time is an estimate, not a measurement. See the formulas sites use, why the minutes differ, and how to check the math by hand in seconds.
  5. Shorts & Reels Safe Zone: Where Captions Get CoveredSee which UI covers your captions on YouTube Shorts, Instagram Reels, and TikTok, plus the exact safe-zone ratios and how to check before you post.
  6. Instagram Link in Bio CSS Builder: Mobile Landing Page CodeLearn the card-size formula and HTML/CSS behind a multi-link landing page for your Instagram bio, plus how to export the code without writing it.

Related tools