How to use the serial number generator
- Type a Pattern. Use X for a character from the chosen set, # for a digit, @ for a letter, and a backslash \ before any character you want to keep literally. Everything else stays as typed.
- Pick the Characters for X: A–Z and 2–9 without look-alikes (the default), A–Z and 0–9, A–Z only, 0–9 only, or Hex 0–F.
- Set How many serials (up to 1,000) and press Generate.
- Copy the list. Possible serials shows how many different values the pattern can make.
What it does and when to use it
Serial numbers label things that need to be told apart: devices on a production line, warranty cards, asset tags, event tickets, gift cards or test records. Most organisations want a fixed shape, such as a short prefix, a dash and a block of characters, so the codes look consistent and are easy to read out over the phone. A pattern gives you that shape and leaves the random part to the tool.
The default character set skips 0, 1, I and O, which are easy to confuse on a printed label. If your serials should count up instead of being random, the order number generator and the invoice number generator make sequential numbers. To turn a serial into a scannable retail barcode number, you need a check digit, which the EAN-13 generator adds.
How it works
The tool reads the pattern one character at a time. Each X, # or @ is replaced by a character chosen with crypto.getRandomValues, with every option equally likely. Repeats within a batch are thrown away and redrawn.
Possible serials is the product of the choices at each placeholder. For TR-XXXX-XXXX with the 32-character default set, that is 32^8 = 1,099,511,627,776. When the number goes above 10^15 the tool shows it as a power of two instead.
Worked examples
- The default pattern.
TR-XXXX-XXXXgives serials likeTR-URXC-UDDBandPossible serials: 1,099,511,627,776. - Digits and letters in fixed places.
SN-####-@@gives values likeSN-0223-CB: 10^4 × 24^2 =5,760,000possible serials. - A literal letter.
\X-##keeps the X fixed and givesPossible serials: 100. - Asking for too many. The pattern
#has only 10 values, so a request for 20 stops with “Only 10 distinct values fit this pattern — ask for fewer or make it longer.”
Limits and tips
- A pattern with no X, # or @ is refused with a message, since every serial would be the same.
- Keep the pool far larger than the number of serials you will ever issue. That makes guessing a valid serial hard.
- Random serials do not sort by date. Add a date or batch prefix to the pattern if you need that.
Frequently asked questions
How do I put a real letter X, # or @ in the serial?
Are the serials unique?
Which letters does @ use?
Can I use these as software licence keys?
How do we know nothing is uploaded? Test it yourself on the privacy proof page.