China Resident ID Format Validator (中国身份证)

Share:

China Resident ID (身份证) format validator using the ISO 7064 MOD 11-2 algorithm. 18 digits: 6 region + 8 birthdate + 3 serial + 1 check. Browser-only.

RT-CHN-068 · Converters & Units
Your browser is too old for this tool’s interactive features. Please update to Safari 13.1, Chrome or Edge 80, Firefox 74 or newer.

China Resident ID Format Validator (中国身份证)

Advertisement
After results · AD-W1Responsive

How to use

Enter the 18-digit ID

Format: 6-digit administrative region + 8-digit birthdate (YYYYMMDD) + 3-digit serial + 1 check digit (0-9 or X).

Identify province

First 2 digits = province code (11=Beijing, 44=Guangdong, 31=Shanghai, etc.). First 6 digits go down to county/district.

Parse birth date + gender

Digits 7-14 are the birth date; the tool checks for a real calendar date. The 17th digit's parity = gender (odd=male, even=female).

ISO 7064 MOD 11-2 check

Apply weights [7,9,10,5,8,4,2,1,6,3,7,9,10,5,8,4,2] to the first 17 digits, mod 11, lookup the expected check character.

About China's 18-digit Resident ID

The PRC Resident Identity Card (居民身份证) is issued by the public security authorities. The State Council brought in the citizen ID number system from 1 October 1999, with numbers built to national standard GB 11643-1999 (in force 1 July 1999, replacing GB 11643-1989) — 18 digits in place of the old 15. The new format adopts the ISO 7064 MOD 11-2 international standard for its check digit — meaning the ID can be validated anywhere in the world, offline.

What the 18 digits mean

Every digit carries meaning: digits 1-2 = provincial region (11=Beijing, 31=Shanghai, 44=Guangdong...); digits 3-4 = prefecture city; digits 5-6 = county/district; digits 7-14 = birth date YYYYMMDD; digits 15-17 = serial (the 17th digit's parity = gender); digit 18 = check character (0-9 or X, where X = Roman numeral 10).

"China's Resident ID is the world's most data-dense national ID — 18 digits packing 7 semantic segments (province / prefecture / county / year / month / day / serial + checksum)."

Practical use cases

The ID is everywhere in China: train tickets, hotel check-in, bank accounts, app signups, ride-hailing, SIM card registration. What the 18th check digit buys is catching typing errors: any single wrong digit, and any two adjacent digits swapped, always fails the check.

Privacy stance

This tool runs entirely in your browser; the ID is never uploaded, logged, or stored. China's Personal Information Protection Law (PIPL) classifies the Resident ID as sensitive personal information — our zero-network design fully complies.

Advertisement
After how-to · AD-W2Responsive

The 17th digit is odd for male and even for female

01

The 18-digit format took effect on 1 October 1999, replacing the older 15-digit format.

02

The check algorithm follows international standard ISO 7064 MOD 11-2 — it catches every single wrong digit and every swap of two adjacent digits.

03

The check character can be "X" — representing Roman numeral 10 when mod 11 remainder = 2.

04

Modern hardware can validate millions of IDs per second — pure offline, no DB lookup needed.

05

The first 6 digits go down to county/district — 3,000+ administrative codes (GB/T 2260 standard).

06

As of 2026, China has ~1.37 billion active Resident IDs — the world's largest single national ID system.

07

The 17th digit's parity determines gender (odd=male, even=female). China is one of few countries encoding gender directly into the ID.

08

HK/Macau/Taiwan Resident Permits (since 2018) also use the 18-digit format with address code 810000 = HK, 820000 = Macau, 830000 = Taiwan (State Council Office, 2018, No. 81).

09

The old 15-digit format = 6 region + 6 birth (YYMMDD, no century) + 3 serial (no checksum). Discontinued for new issuance after 1999.

10

China's PIPL classifies the Resident ID as sensitive personal information — this tool's zero-network design fully complies.

📅 Research current as of 08 Oct 2026 · Sources: General Office of the State Council, 国办发〔2018〕81号, Article 3 (address codes 810000 / 820000 / 830000 for Hong Kong, Macao and Taiwan residents). The check character and the birth-date test are computed in your browser; no network calls.
Standards, published formulas, and reference data are revised over time — check against a current authoritative source before relying on these figures.

Frequently Asked Questions

  • No. The validation runs entirely in your browser — the ID is never uploaded, logged, or stored.

  • No. It only confirms the ID satisfies the ISO 7064 algorithm + has a real birth date. Real authenticity needs an MPS networked lookup.

  • Yes. When mod 11 remainder = 2, the check character is X (Roman numeral 10). About 9% of IDs end in X.

  • Administrative codes (GB/T 2260): first 2 = province, first 4 = prefecture city, first 6 = county/district. E.g. 110105 = Chaoyang District, Beijing.

  • Currently only to province level (33 provinces/municipalities/autonomous regions/SARs). County/district resolution needs a 3000+ row lookup table — planned for a future version.

  • No. This tool supports the current 18-digit format only. Old 15-digit IDs need to be upgraded to 18 digits at an MPS office first.

  • Yes. Digits 7-14 are the birth date in YYYYMMDD format — the tool displays the parsed birth date.

  • Yes. Official spec: 17th digit odd=male, even=female. Unchanged since 1999.

  • Yes. HK/Macau/Taiwan resident permits (since 2018) also use 18-digit ISO 7064 with prefix 81=HK, 82=Macau, 83=Taiwan.

  • Yes. All RECATOOLS tools are 100% free, ad-supported. No signup, no paywall.

Method & sources

How it computes

18 characters per GB 11643-1999: 6-digit address code, 8-digit birth date, 3-digit sequence (odd = male) and an ISO 7064 MOD 11-2 check: weights 2^(17−i) mod 11 over the first 17 digits, check = (12 − sum mod 11) mod 11, with 10 written X.

What this tool implements

  • GB 11643-1999 《公民身份号码》, in force from 1 July 1999; the State Council brought the ID-number system in from 1 October 1999 (国发〔1999〕15号).
  • Residence permits for Hong Kong, Macau and Taiwan residents use address codes 810000, 820000 and 830000 (国办发〔2018〕81号); the tool accepts all three.
  • The check digit catches every single wrong digit and every swap of two adjacent digits — confirmed by brute force over 489,000 substitutions and 45,920 transpositions.

Sources

Advertisement
Pre-footer · AD-W3 728 × 90