Skip to main content
CodeLint.Dev AI · Dev · Finance

Indian ID Validator

Check whether a GSTIN, PAN, TAN, IFSC, Aadhaar number, CIN or Udyam number is well-formed, see what each part encodes, and find the character that is wrong. Format only: it cannot confirm that an identifier is issued or active.

Mode

Checked in your browser: nothing you enter is sent anywhere or stored. Format only: this checks structure and check digits and cannot confirm that an identifier has been issued or is still active.

Lower case, spaces and hyphens are fine; they are removed before checking.

Sample. Synthetic. State 27 (Maharashtra), a company PAN, entity code 1Z, check character J.

Result

Well-formed GSTIN. Format only: this does not show it has been issued or is active.

Detected as GSTIN, Goods and Services Tax Identification Number: 2 digits (State code), 10 characters (PAN or TAN), 2 characters (entity code), 1 check character.

Parts

  • Fits: Characters 1–2 · State code 27 Maharashtra.
  • Fits: Characters 3–5 · PAN: series ZZZ Alphabetic series, running from AAA to ZZZ.
  • Fits: Character 6 · PAN: holder type C Company.
  • Fits: Character 7 · PAN: name initial Z First letter of the holder's name.
  • Fits: Characters 8–11 · PAN: number 9999 Sequential number, 0001 to 9999.
  • Fits: Character 12 · PAN: check letter Z Alphabetic check digit. How it is worked out is not published, so it is not verified here.
  • Fits: Characters 13–14 · Entity code 1Z Two characters for the entity code. By convention the 13th counts the registrations under the same PAN in the State (1 to 9, then A to Z) and the 14th is Z by default.
  • Fits: Character 15 · Check character J Checksum over the first 14 characters.

Checks 0 errors · 0 warnings · 5 passed

  • Passed:Length is 15 characters.
  • Passed:State code 27: Maharashtra.
  • Passed:PAN holder type "C": Company.
  • Passed:The embedded PAN has the right layout: five letters, four digits, one letter.
  • Passed:The check character "J" matches the first 14 characters (by the commonly implemented method; GSTN does not publish one).

The identifiers, side by side

Lengths are counted after removing spaces and hyphens, except for the Udyam number, whose hyphens are part of how it is written.

IdentifierLengthPatternIssued byCheck digit
GSTIN — Goods and Services Tax Identification Number152 digits, 10 characters (a PAN or a TAN), 2 characters, 1 check characterGST authorities, through the GST common portalYes, the 15th character. Verified by the commonly implemented method
PAN — Permanent Account Number105 letters, 4 digits, 1 letterIncome Tax DepartmentThe 10th letter is a check digit, but its method is not published, so it is not verified
TAN — Tax Deduction and Collection Account Number104 letters, 5 digits, 1 letterIncome Tax DepartmentNone published
IFSC — Indian Financial System Code114 letters, the digit 0, 6 charactersReserve Bank of IndiaNone
Aadhaar number1212 digits, the first from 2 to 9Unique Identification Authority of India (UIDAI)Yes, the 12th digit, by the Verhoeff scheme
CIN — Corporate Identity Number21L or U, 5 digits, 2 letters, 4 digits, 3 letters, 6 digitsMinistry of Corporate AffairsNone
Udyam Registration Number19UDYAM-XX-00-0000000Ministry of Micro, Small and Medium EnterprisesNone

Sources, all read on 23 November 2026: rule 10 of the CGST Rules; the Income Tax Department's tutorials on PAN and TAN; the RBI's NEFT FAQ; UIDAI's numbering scheme paper; the Annual Survey of Industries manual for the CIN; the Udyam Registration portal.

The anatomy of a GSTIN, position by position

The example is 27ZZZCZ9999Z1ZJ, a synthetic GSTIN that passes every check. Rule 10(1) of the CGST Rules fixes the four parts: two characters for the State code, ten for the PAN or TAN, two for the entity code and one checksum character.

PositionExamplePartWhat it holdsHow it is checked
1–227State codeThe State or Union Territory of registration: 27 is MaharashtraTwo digits that must be in the State code table below
3–5ZZZPAN: seriesThe first three letters of the holder's PANLetters
6CPAN: holder typeThe kind of taxpayer: C is a companyOne of the ten letters in the PAN table below
7ZPAN: name initialFirst letter of the surname (individuals) or of the name (everyone else)A letter
8–119999PAN: numberA sequential numberFour digits, 0001 to 9999
12ZPAN: check letterThe PAN's own check digitA letter. Not recomputed: the method is not published
13–141ZEntity codeTwo characters. By convention the 13th counts the registrations under the same PAN in the State (1 to 9, then A to Z) and the 14th is Z by defaultLetters or digits. Never reported as an error
15JCheck characterA checksum over the first 14 charactersRecomputed; see the worked example below

For a registered tax deductor or collector, positions 3–12 hold a TAN (four letters, five digits, one letter) instead of a PAN, which rule 10 allows. The character set comes from the e-invoice API schema, whose GSTIN pattern is two digits followed by thirteen digits or capital letters. The meaning of the 13th and 14th characters beyond "entity code" is the usual description, not something in the rule. Read on 23 November 2026.

GST State codes

The first two digits of a GSTIN. A GSTIN that starts with anything else is not well-formed.

CodeState or Union TerritoryCodeState or Union Territory
01Jammu and Kashmir21Odisha
02Himachal Pradesh22Chhattisgarh
03Punjab23Madhya Pradesh
04Chandigarh24Gujarat
05Uttarakhand25Daman and Diu
06Haryana26Dadra and Nagar Haveli and Daman and Diu
07Delhi27Maharashtra
08Rajasthan29Karnataka
09Uttar Pradesh30Goa
10Bihar31Lakshadweep
11Sikkim32Kerala
12Arunachal Pradesh33Tamil Nadu
13Nagaland34Puducherry
14Manipur35Andaman and Nicobar Islands
15Mizoram36Telangana
16Tripura37Andhra Pradesh
17Meghalaya38Ladakh
18Assam96Other countries
19West Bengal97Other Territory
20Jharkhand99Other countries

From the State code list in the master codes of the GST e-invoice system, read on 23 November 2026. There is no code 28 in that list or in the e-way bill system's list. The e-way bill list names 26 "Dadra and Nagar Haveli & Daman and Diu" and omits 25; the e-invoice list still shows 25 as Daman and Diu. The e-invoice schema uses 96 for a place of supply outside India, so the tool accepts it at the start of a GSTIN with a warning.

The fourth character of a PAN

A PAN is five letters, four digits and a letter. The first three letters are a series running from AAA to ZZZ; the fourth says what kind of holder the PAN belongs to; the fifth is the first letter of the holder's surname for an individual, and of the holder's name for everyone else; the digits run from 0001 to 9999; the last letter is an alphabetic check digit.

Fourth characterHolder
PIndividual
CCompany
HHindu Undivided Family (HUF)
AAssociation of Persons (AOP)
BBody of Individuals (BOI)
GGovernment Agency
JArtificial Juridical Person
LLocal Authority
FFirm or Limited Liability Partnership
TTrust

From the Income Tax Department's tutorial on PAN, read on 23 November 2026 from an archived copy because the department's site refuses scripted requests. Any other fourth letter is reported as an error. This is why the familiar placeholder ABCDE1234F fails: D is not a holder type.

TAN, IFSC, Aadhaar, CIN and Udyam, part by part

IdentifierPositionPartWhat it holds
TAN1–3Jurisdiction codeThree letters for the jurisdiction. The department's example is DEL in DELM12345L
TAN4Name initialFirst letter of the name of the TAN holder
TAN5–9NumberFive digits
TAN10Last letterA letter
IFSC1–4Bank codeFour letters that represent the bank
IFSC5Fifth characterAlways the digit 0
IFSC6–11Branch codeSix characters that represent the branch
Aadhaar1First digit2 to 9. 0 is reserved for a future longer number and 1 for entities
Aadhaar2–11NumberRandomly generated; it carries no information about the holder
Aadhaar12Check digitVerhoeff check digit over the first eleven digits
CIN1Listing statusL for a listed company, U for one that is not listed
CIN2–6Industry codeFive digits from the National Industrial Classification
CIN7–8State codeTwo letters, for example MH for Maharashtra
CIN9–12Year of incorporationThe calendar year the company was formed
CIN13–15Ownership codeGOI Union Government, SGC State Government, PLC public limited, PTC private limited, FLC and FTC public and private foreign companies incorporated in India, ULL and ULT unlimited liability public and private, GAP and GAT guarantee and association public and private, NPL section 25 company
CIN16–21Registration numberSix digits: the registration number with the Registrar of Companies
Udyam1–5PrefixThe word UDYAM
Udyam7–8Two lettersTwo letters. Commonly read as the State or Union Territory; the portal states only the layout
Udyam10–11Two digitsTwo digits. Commonly read as a district number; the portal states only the layout
Udyam13–19Seven digitsSeven digits

TAN from the Income Tax Department's tutorial on TAN. IFSC from question 4 of the RBI's NEFT FAQ. Aadhaar from UIDAI's A UID Numbering Scheme (2010). CIN from section 3.3.3 of the Ministry of Statistics' Annual Survey of Industries manual, 2021-22: an official secondary source, used because no Ministry of Corporate Affairs description could be obtained; its list of ownership codes ends in "etc.", so an unlisted code is not treated as an error. Udyam from the validation message on the Udyam Registration portal's sign-in form. All read on 23 November 2026.

How the GSTIN check character is worked out

This is the commonly implemented method. Rule 10 says only that the 15th character is a checksum; no official text we could find describes the calculation. The method below reproduces the check character of six sample GSTINs in the government's e-way bill API documentation.

check = (36 − (Σ (⌊pᵢ ÷ 36⌋ + pᵢ mod 36)) mod 36) mod 36, where pᵢ = vᵢ × fᵢ

vᵢ
the value of the i-th of the first 14 characters: 0–9 are 0–9, A is 10, B is 11 … Z is 35
fᵢ
the factor: 1 for the 1st, 3rd, 5th … character and 2 for the 2nd, 4th, 6th …
pᵢ
the product vᵢ × fᵢ; its quotient and remainder on division by 36 are added together
check
a value from 0 to 35, written with the same alphabet: 0–9, then A–Z

Worked example

First 14 characters
2 9 A A A A A 1 3 0 3 P 1 Z
Values
2, 9, 10, 10, 10, 10, 10, 1, 3, 0, 3, 25, 1, 35
Factors
1, 2, 1, 2, 1, 2, 1, 2, 1, 2, 1, 2, 1, 2
Products
2, 18, 10, 20, 10, 20, 10, 2, 3, 0, 3, 50, 1, 70
Quotient + remainder
2, 18, 10, 20, 10, 20, 10, 2, 3, 0, 3, 15 (1 + 14), 1, 35 (1 + 34)
Sum
149
149 mod 36
5
36 − 5
31, which is the letter V

The check character is V, so the GSTIN is 29AAAAA1303P1ZV.

29AAAAA1303P1ZV is a sample from the NIC e-way bill API documentation, read on 23 November 2026. The same pages contain placeholders such as 29ABCDE8755F1Z2 whose last character does not follow the method; they are not real registrations.

How the Aadhaar check digit is worked out (Verhoeff)

UIDAI's numbering paper recommends the Verhoeff scheme because it catches every single wrong digit and every swap of two neighbouring digits, and its developer documentation says a number "should be 12 digits and conform to Verhoeff algorithm". UIDAI's paper shows the tables only as a figure; the tables below are the standard published ones, and they validate all eleven test numbers UIDAI published.

c ← d[c][ p[i mod 8][nᵢ] ] for each digit, right to left, starting from c = 0; check digit = inv[c]

nᵢ
the i-th digit of the first eleven, counted from the right, starting at i = 1
p
the permutation table: row i mod 8, column nᵢ
d
the multiplication table of the dihedral group D5: row c, column the permuted digit
inv
the inverse table: 0→0, 1→4, 2→3, 3→2, 4→1, and 5 to 9 map to themselves

Worked example

First eleven digits
9 9 9 9 9 9 9 9 0 0 1 (read from the right: 1, 0, 0, 9, 9, 9, 9, 9, 9, 9, 9)
i = 1, digit 1
p[1][1] = 5; d[0][5] = 5
i = 2, digit 0
p[2][0] = 5; d[5][5] = 0
i = 3, digit 0
p[3][0] = 8; d[0][8] = 8
i = 4, digit 9
p[4][9] = 0; d[8][0] = 8
i = 5, digit 9
p[5][9] = 1; d[8][1] = 7
i = 6, digit 9
p[6][9] = 5; d[7][5] = 2
i = 7, digit 9
p[7][9] = 8; d[2][8] = 5
i = 8, digit 9
p[0][9] = 9; d[5][9] = 1
i = 9, digit 9
p[1][9] = 4; d[1][4] = 0
i = 10, digit 9
p[2][9] = 2; d[0][2] = 2
i = 11, digit 9
p[3][9] = 7; d[2][7] = 9
inv[9]
9

The check digit is 9, giving 9999 9999 0019, the first of UIDAI's published test numbers.

To validate a whole number instead, run the same loop over all twelve digits with i starting at 0 for the check digit; the number is consistent when c ends at 0.

The Verhoeff tables

Rows d0 to d9 are the multiplication table d (row c, column the permuted digit). Rows p0 to p7 are the permutation table p (row i mod 8, column the digit).

Row0123456789
d00123456789
d11234067895
d22340178956
d33401289567
d44012395678
d55987604321
d66598710432
d77659821043
d88765932104
d99876543210
p00123456789
p11576283094
p25803796142
p38916043527
p49453126870
p54286573901
p62793806415
p77046913258
inv0432156789

These are the tables in general use for the Verhoeff scheme. They are not copied from a UIDAI text; they are confirmed against UIDAI's test numbers.

What the tool reports, and what to do about it

The messages below are the ones people meet most. In each case the fix is to go back to the source document — the registration certificate, the PAN card, the cheque leaf — not to adjust the identifier until it passes.

The check character is "5", but for these first 14 characters it should be "J"

Cause: One character of the GSTIN was mistyped. It may be the last one, but it is as likely to be one of the first fourteen: look-alikes such as 0 and O, 1 and I, 5 and S, 8 and B, 2 and Z are the usual suspects.

Fix: Compare the whole GSTIN with the registration certificate or an invoice from the supplier. Do not simply replace the last character with the one suggested: that makes the checksum agree with a number that may still be wrong.

"28" is not in the list of GST State codes

Cause: The first two digits are not a State code. Either they were mistyped, or the value is not a GSTIN at all, or characters were lost from the front.

Fix: Check the first two digits against the State code table above. The code is the State of registration, which is not always the State of the address you have on file.

A GSTIN has 15 characters; this has 14

Cause: A character was dropped or added in copying, or two fields were joined. A 10-character value in a GSTIN column is usually a PAN.

Fix: Re-copy the value. In bulk mode, filter to the lines with problems and look at the lengths: a column where every line is one short has usually lost its check character in an export.

The fourth character of a PAN is the holder's status and must be one of A, B, C, F, G, H, J, L, P or T

Cause: The PAN is a placeholder such as ABCDE1234F, or two letters were swapped. Inside a GSTIN the same rule applies to position 6.

Fix: Ask for the PAN again. A PAN whose fourth letter does not match the kind of entity you are dealing with — P for a company, say — is well-formed but worth a second look.

The fifth character of an IFSC is the digit 0 (zero). Position 5 is the letter O

Cause: The reserved zero was typed, or read by OCR, as the letter O.

Fix: Replace it with a zero. The same confusion can occur in the six-character branch code, where the tool cannot detect it because both letters and digits are allowed there.

The Verhoeff check digit does not match

Cause: One digit of the Aadhaar number is wrong, or two neighbouring digits were swapped. The Verhoeff scheme catches every error of both kinds.

Fix: Re-read the number from the Aadhaar letter or card. The tool says what the last digit would be for the first eleven as typed, but the mistake may be in any position.

An Aadhaar number issued to a person does not start with 1

Cause: UIDAI reserved numbers starting with 0 and 1, so a 12-digit number that starts with either is something else: a specimen such as 1234 5678 9012, an enrolment or account number, or a mobile number with a prefix.

Fix: Check which number you were given. If the type was detected automatically, the value may simply be another 12-digit number.

An Udyam Registration Number … starts with the word UDYAM

Cause: The value is not in the form UDYAM-XX-00-0000000. An older Udyog Aadhaar Memorandum number is a different, 12-character identifier (two letters, two digits, a letter, seven digits, like DL05A0000001).

Fix: Ask for the Udyam Registration Number printed on the Udyam certificate.

Not recognised as a GSTIN, PAN, TAN, IFSC, Aadhaar number, CIN or Udyam number

Cause: The value does not resemble any of the seven closely enough to say which it was meant to be: it is the wrong length by more than one character, or is some other kind of number.

Fix: Choose the type under "Type". The tool then checks the value as that identifier and says what is wrong with it.

What is checked, and what each check rests on

Every check that can report an error rests on a document read on 23 November 2026. Where the basis is common practice instead, it says so here and in the tool.

About

The Indian ID Validator checks whether an Indian business or tax identifier is well-formed and shows what each part of it encodes. It reads seven identifiers: the GSTIN, the PAN, the TAN, the IFSC, the Aadhaar number, the company CIN and the Udyam registration number. Enter one and it works out which it is, cuts it into its parts — the State code, embedded PAN, entity code and check character of a GSTIN; the holder type in the fourth character of a PAN; the bank and branch codes of an IFSC — and says exactly which character position is wrong and why. For a GSTIN it recomputes the check character and, when only that is wrong, says what it should be; for an Aadhaar number it verifies the Verhoeff check digit. A bulk mode takes a pasted column of mixed identifiers, thousands of lines long, and reports on each line. The tool checks format only. It does not contact the GST portal, the Income Tax Department, UIDAI, a bank or any other system, so it cannot tell you whether an identifier has actually been issued, to whom, or whether it is still active. Everything runs in your browser: nothing you enter is sent anywhere or stored, and Aadhaar numbers are masked to their last four digits in anything you copy.

How to use

  1. 1 Type or paste an identifier into "Identifier". The page opens on a synthetic GSTIN so you can see a full report first. Lower case, spaces and hyphens are fine.
  2. 2 Leave "Type" on automatic detection, or choose the type yourself when the value is too damaged to recognise — a forced type shows what is wrong with it as that kind of identifier.
  3. 3 Read "Result" first, then "Parts": each part of the identifier with its position, its value and what it means. A part with a problem is outlined and labelled.
  4. 4 "Checks" lists every rule that passed or failed, with the character positions at fault. For a GSTIN with a wrong check character it gives the character the first 14 would produce.
  5. 5 For a list, switch to "A column of them" and paste one identifier per line. Tick "Only lines with problems" to see the failures, and use "Copy as CSV" to take the results back to a spreadsheet. Aadhaar numbers are masked in the copy unless you untick the masking box.
If the tool says an identifier is well-formed, is it genuine?
Not necessarily. Well-formed means the characters are in the right places and any check digit matches. The tool never contacts a government system, so it cannot tell you whether the GSTIN is registered or cancelled, whether the PAN exists, who holds it, or whether the IFSC belongs to a real branch. A made-up identifier can pass. To confirm that an identifier is real, ask the authority that issues it: the GST portal for a GSTIN, the Income Tax Department for a PAN or TAN, your bank or the RBI's published list for an IFSC, UIDAI for Aadhaar, the Ministry of Corporate Affairs for a CIN.
Is it safe to enter an Aadhaar number here?
The check runs in JavaScript in your browser. The page makes no request with what you type, does not write it to local storage or cookies, and forgets the number when you close or reload the tab. Anything you copy from the page — a single result or the CSV — shows only the last four digits unless you untick the masking box. That said, an Aadhaar number is sensitive personal data: check one only when you have a reason to, prefer a masked copy wherever a full number is not required, and do not paste other people's numbers into any website you have not satisfied yourself about, this one included.
How is the GSTIN check character worked out, and is the method official?
Rule 10 of the CGST Rules says the last character of a GSTIN is a "checksum character" but does not say how it is computed, and we found no GSTN or CBIC text that does. The tool uses the method that software across India implements: give each of the first 14 characters a value from 0 to 35, multiply alternate values by 1 and 2, add the quotient and remainder of each product on division by 36, and take 36 minus the total modulo 36. It reproduces the check character of six sample GSTINs printed in the government's e-way bill API documentation, which is strong evidence, but it is still common practice rather than a published rule, and the page labels it that way.
Why is ABCDE1234F rejected as a PAN?
Because its fourth letter is D. The fourth character of a PAN states what kind of holder it belongs to, and the Income Tax Department lists ten letters for it: P, C, H, A, B, G, J, L, F and T. D is not one of them, so ABCDE1234F is a placeholder that could never be issued. The same holds for a GSTIN built on it, such as the 29ABCDE8755F1Z2 used in some API examples.
Can it tell me which bank or branch an IFSC belongs to?
No. It checks the layout the Reserve Bank of India describes — four letters for the bank, a zero, six characters for the branch — and nothing more. It holds no list of banks or branches, so a code can pass here and still not exist. The RBI publishes the list of IFSCs for branches in NEFT, and your bank prints the code on its cheques.
Does it accept the GSTIN of a tax deductor, which has no PAN in it?
Yes. Rule 10 allows characters 3 to 12 of a GSTIN to be either a PAN or a TAN. When those ten characters have the TAN layout (four letters, five digits, one letter) the tool reports a TAN-based registration and checks the State code and check character as usual. Identity numbers issued to UN bodies and embassies, non-resident taxpayers and overseas online-service providers use other layouts, which the tool does not know and will report as faulty GSTINs.
Which identifiers are not covered, and why?
LLPIN (for limited liability partnerships), FSSAI licence numbers and the special GST identity numbers mentioned above. The rule for this tool is that every error it reports must rest on a document we have read, and for these we could not obtain an official description of the format. It also does not check a PAN's final check letter, because the Income Tax Department does not publish how that letter is computed.