Random Number 1-100: How to Generate One

How-to basics · Updated November 23, 2026

The direct answer: there is no single true random number between 1 and 100 — any number you pick has an equal 1% chance. To actually generate one, use a physical randomizer (dice, coins, a shuffled deck) or a good software random number generator (RNG) like RAND() in Excel, random.randint(1,100) in Python, or a dedicated website. The method you choose depends on whether you need true unpredictability or just something quick and fair.

Why “Random” Is Harder Than It Looks

Humans are terrible at picking random numbers. Studies and classroom demonstrations consistently show that when people are asked to pick a number from 1 to 100, they cluster around 37, 42, and 69, and they avoid numbers ending in 0 or 5. That’s because our brains look for patterns, and we unconsciously avoid numbers that feel “too obvious.” If you need a random number for a lottery, a drawing, or a scientific sample, your own brain is the worst tool.

True randomness means each number has exactly the same probability of being chosen, and the outcome of one pick gives no information about the next. No human can do that reliably. Instead, we use devices or algorithms that approximate randomness.

Physical Randomizers: Dice, Coins, and Cards

If you want a random number without any technology, you can use common objects. Here are three practical methods:

  • Two ten-sided dice (d10): Roll one die for the tens digit (0–9) and one for the ones digit (0–9). If you get 00, treat it as 100. This gives a uniform 1–100 result.
  • A standard deck of cards: Assign numbers to cards (e.g., A=1, J=11, Q=12, K=13, and suits for tens). Shuffle well, draw two cards, and map them to a number. It’s more work but works.
  • Coins and a binary method: Flip a coin 7 times. Heads=1, tails=0. That gives a binary number from 0 to 127. If it’s 0 or over 100, redo. This is mathematically correct but tedious.

Physical methods are truly random if the objects are fair and you use them correctly. The downside is they’re slow and error-prone.

Software Generators: How They Work

Most software “random” numbers are not truly random. They come from a pseudorandom number generator (PRNG) — an algorithm that produces a sequence of numbers that looks random but is actually deterministic. The sequence is seeded by a starting value (often the current time). If you know the seed, you can predict the entire sequence. For games, simulations, and everyday uses, that’s fine. For cryptography or gambling, you need a cryptographically secure RNG that uses entropy from your computer’s hardware (like mouse movements or thermal noise).

Common PRNGs include the Mersenne Twister (used in Python and many languages) and the linear congruential generator (used in older C libraries). They pass statistical tests for randomness, but they are not truly random.

How to Generate a Random Number in Excel

In Microsoft Excel (Microsoft 365 on Windows), you have two main functions:

  • =RAND() returns a decimal between 0 and 1. To get an integer from 1 to 100, use =INT(RAND()*100)+1. This works in any version of Excel.
  • =RANDBETWEEN(1,100) returns an integer directly. This is simpler and works in Excel 2007 and later.

Both recalculate every time the worksheet changes, so if you want to freeze the number, copy the cell and paste as values (right-click > Paste Special > Values). On Mac, the same functions work; the ribbon path is the same.

For a more advanced approach, you can use the RANDARRAY function (Excel 365 only) to generate a list of random numbers. For example, =RANDARRAY(10,1,1,100,TRUE) creates 10 random integers between 1 and 100 in a vertical column.

How to Choose a Random Number Generator

Your choice depends on your need:

  • Casual use (picking a winner, deciding who goes first): Any online generator or Excel’s RANDBETWEEN is fine.
  • Statistical sampling or simulations: Use a well-tested PRNG like Python’s random module (Mersenne Twister) or R’s sample().
  • Security-sensitive (passwords, encryption, gambling): Use a cryptographically secure generator like Python’s secrets module, or the random.SystemRandom() class.
  • Fairness in a public drawing: Use a physical method or a verified third-party service, so people trust the result.

If you’re using a website, check that it states it uses a “cryptographically secure” generator if it matters. Many free sites use the browser’s built-in Math.random(), which is not secure but is fine for casual use.

Common Pitfalls and Misconceptions

One common mistake is using Math.random() in JavaScript without rounding correctly. For example, Math.floor(Math.random()*100)+1 gives 1–100, but Math.ceil(Math.random()*100) can give 0 in rare cases. Always use floor and add 1.

Another misconception is that a random number generator “remembers” previous numbers. In a uniform generator, each pick is independent — getting 42 once doesn’t make 43 more or less likely. That’s the gambler’s fallacy.

Also, beware of biased methods. For instance, using a single six-sided die and rerolling 6s to get 1–5 is fine, but using a die to generate 1–100 by rolling once and multiplying is not uniform. Always use the methods described above.

Frequently Asked Questions

Can I use my phone’s calculator to generate a random number? Most basic calculators don’t have a random function. But you can use a scientific calculator’s Ran# key (on Casio models) or the rand() function on TI calculators. On a smartphone, use a dedicated app or a website.

Is there a way to get a truly random number from a computer? Yes, using hardware random number generators. Modern CPUs have instructions like Intel’s RDRAND that use physical entropy. Operating systems also provide secure random sources (e.g., /dev/urandom on Linux, CryptGenRandom on Windows). Those are truly random for practical purposes.

Why do online random number generators ask for a “seed”? A seed lets you reproduce the same sequence of numbers. If you set a seed, you get the same “random” numbers each time. That’s useful for testing or simulations, but not for gambling or security.

What is the most common random number people pick? In informal surveys, the number 37 is often the most common, followed by 42 and 69. That’s why using a machine is better if you want a fair pick.

Can I use a random number generator to win the lottery? No. Lottery numbers are drawn independently, and a random generator cannot predict them. It can help you pick a set of numbers, but every combination has the same odds. The only way to improve your expected value is to avoid popular numbers (like birthdays) to reduce the chance of splitting a jackpot.

Alternatives to a Single Number

Sometimes you need more than one random number. For a list of unique random numbers from 1 to 100, you can use Excel’s SORTBY with RANDARRAY. For example, to get 5 unique numbers:

  1. In A1, enter =SORTBY(SEQUENCE(100),RANDARRAY(100))
  2. This creates a shuffled list of 1–100 in column A.
  3. Take the first 5 cells (A1:A5) for your random sample.

That works in Excel 365. In older versions, you can use a helper column with =RAND() and sort, but it’s more manual.

For a random number between 1 and 100 with a different distribution (e.g., weighted), you’d need a custom algorithm, but that’s beyond the scope of this article.

Related

Try it: the Date Difference Calculator: days, months, years and weekdays between two dates, with the DATEDIF formulas.

More in How-to basics

Sources: Function behaviour and menu paths: Microsoft Support documentation for Excel. Method & sources

Spotted an error in this guide? Let us know.