South Africa ID Number Validator

Validate a South African 13-digit ID number with the Luhn check digit.

Ad placeholder (leaderboard)

A South African ID number is a 13-digit identifier issued by the Department of Home Affairs that encodes a person’s date of birth, sex, and citizenship status, finished with a Luhn check digit. This free validator parses all of that and confirms the check digit in your browser.

How it works

The 13 digits break down as YYMMDD GGGG C R Z:

  1. YYMMDD — date of birth. The day must be valid for the decoded month.
  2. GGGG — gender sequence: 00004999 is female, 50009999 is male.
  3. C — citizenship: 0 is a South African citizen, 1 is a permanent resident.
  4. R — a historical race digit, now obsolete and usually 8. It is ignored.
  5. Z — the Luhn check digit over the first twelve digits.

The Luhn check works from the right: double every second digit, subtract 9 from any doubled value above 9, sum all digits, and the total must be a multiple of 10.

Example

Take 8001015009087. The date 800101 decodes to 1 January 1980. The gender block 5009 is at or above 5000, so the person is male. The citizenship digit 0 marks a citizen. Running Luhn across all 13 digits gives a sum divisible by 10, so the check digit passes and the number is valid.

Notes

A valid result confirms the number is internally consistent and passes the Luhn check — it does not prove the number was issued to a real person. Because an ID number is sensitive personal data, all processing here is local and nothing is uploaded.

Ad placeholder (rectangle)