A fake SSN for testing is a number shaped like a US Social Security Number — XXX-XX-XXXX — taken from a range that is never issued, so it can appear in fixtures, screenshots and demos without identifying anyone. This generator uses area numbers 900–999, which the Social Security Administration has never assigned, and keeps the group number at 01–49 so the result is not a real Individual Taxpayer Identification Number either.
It also generates five other national identifiers: US ITINs, UK National Insurance numbers, Canadian Social Insurance Numbers, Brazilian CPFs and French INSEE numbers, each with the check digits its scheme defines.
How to use it
- Pick a scheme.
- Toggle separators to test both the printed form (
956-34-7382,2 66 09 83 626 295 35) and the compact form you store. - Generate as many rows as your fixture needs, and export them as JSON, CSV or SQL.
- For full user records, pair this with the name generator and date of birth generator using the same seed.
What you can control
- US SSN: area 900–999, group 01–49, serial 0001–9999 — never valid as an SSN or an ITIN.
- US ITIN: starts with 9, with a middle group from the IRS's ITIN ranges.
- UK National Insurance number: two prefix letters from the permitted set, six digits and a suffix A–D.
- Canada SIN: nine digits with a Luhn check digit, in the 9xx range used for temporary residents.
- Brazil CPF: nine digits plus two mod-11 check digits.
- France INSEE (NIR): sex, birth year and month, département, commune and order number, then the two-digit control key.
- With or without separators.
Which numbers are never issued
The SSA has committed never to issue:
- area
000,666, or900–999 - group
00 - serial
0000
Since randomised assignment began in June 2011, area numbers no longer encode the state where the number was issued, so geography-based checks are obsolete. Checks against the rules above still hold.
The 9xx block is shared with ITINs, which are real numbers issued to real taxpayers. ITIN groups are 50–65, 70–88, 90–92 and 94–99, so an "SSN" like 912-78-1234 might be someone's ITIN. That is why the SSN mode here never goes above group 49.
How the CPF check digits work
Take the base 111.444.777. Multiply the nine digits by 10, 9, 8 … 2 and add them: 162. Then 162 × 10 mod 11 = 3, the first check digit (a result of 10 becomes 0). Append it, multiply the ten digits by 11, 10 … 2: 204. Then 204 × 10 mod 11 = 5. The full CPF is 111.444.777-35.
The French INSEE key is simpler: 97 minus the first thirteen digits mod 97.
Testing ideas
- Area validation. Feed a 9xx SSN to your validator. If it is accepted, your validation is format-only — decide whether that is what you want.
- Masking. Confirm only the last four digits appear in the UI, exports, emails and logs.
- Leading zeros. Real SSNs can start with
0. Store one as a number and it becomes eight digits. Test with a handcrafted001-01-0001-style value alongside the generated ones. - International forms. A form that only accepts
\d{3}-\d{2}-\d{4}will reject every NINO and CPF. Generate one of each if you serve those countries.
What this is not
These numbers are for software testing. They will not pass an SSA or IRS verification and must never be offered as a real identifier. For the full list of reserved ranges across phones, IPs, domains and IDs, read Reserved ranges for test data.