A GSTIN is the 15-character number you get when you register for GST. Each character has a job. The last one is the checksum digit (also called the check digit): it is worked out from the other 14. This lets software catch most typos before a wrong GSTIN goes on an invoice.
This post explains each character, shows how the checksum digit is worked out, and explains what a "valid" or "invalid" result really means. To check a GSTIN now, use the GSTIN Validator.
The 15 characters
Take the sample GSTIN 27AAPFU0939F1ZV:
| Characters | In the sample | What it means |
|---|---|---|
| 1–2 | 27 | State code. 27 is Maharashtra. |
| 3–12 | AAPFU0939F | The PAN of the business. |
| 13 | 1 | Registration number for this PAN in this state. |
| 14 | Z | Fixed letter. Z for a normal registration. |
| 15 | V | Checksum digit, worked out from the first 14. |
A few things to know about each part:
- State code. It is the state where you are registered, not where your head office is. A business in three states has three GSTINs, each with its own code. See multi-state registration and the Master TRN.
- PAN. The 4th letter of the PAN shows the type of holder. In the sample it is F, so the holder is a firm. P is an individual, C is a company and H is a Hindu Undivided Family (HUF).
- 13th character. The first registration for a PAN in a state is 1. A second one in the same state is 2. After 9, letters are used.
- 14th character. Z for a normal registration. Some special registrations use another letter.
How the GSTIN checksum digit is worked out
The method is called "Luhn mod 36". It is not written in the CGST Act or Rules. GSTN's system uses it, and the same method is published in open-source code such as python-stdnum. It matches real GSTINs.
Step 1: give each character a value. Digits keep their value (0 to 9). Letters go from A = 10 to Z = 35.
Step 2: multiply. Start from the 14th character and go left. Multiply the 14th by 2, the 13th by 1, the 12th by 2, and so on.
Step 3: split each product by 36. If a product is 36 or more, divide it by 36. Add the result and the remainder. Example: 70 ÷ 36 = 1, remainder 34. So 70 becomes 1 + 34 = 35.
Step 4: add them up and find the check digit. Divide the total by 36 and take the remainder. Subtract the remainder from 36. The answer is the value of the check digit. (If the remainder is 0, the check digit is 0.)
Here is the sample, 27AAPFU0939F1Z:
| Position | Character | Value | × | Product | After step 3 |
|---|---|---|---|---|---|
| 1 | 2 | 2 | 1 | 2 | 2 |
| 2 | 7 | 7 | 2 | 14 | 14 |
| 3 | A | 10 | 1 | 10 | 10 |
| 4 | A | 10 | 2 | 20 | 20 |
| 5 | P | 25 | 1 | 25 | 25 |
| 6 | F | 15 | 2 | 30 | 30 |
| 7 | U | 30 | 1 | 30 | 30 |
| 8 | 0 | 0 | 2 | 0 | 0 |
| 9 | 9 | 9 | 1 | 9 | 9 |
| 10 | 3 | 3 | 2 | 6 | 6 |
| 11 | 9 | 9 | 1 | 9 | 9 |
| 12 | F | 15 | 2 | 30 | 30 |
| 13 | 1 | 1 | 1 | 1 | 1 |
| 14 | Z | 35 | 2 | 70 | 35 |
| Total | 221 |
- 221 ÷ 36 = 6, remainder 5.
- 36 − 5 = 31.
- The character with value 31 is V.
So the check digit is V, and 27AAPFU0939F1ZV passes.
Example of a typo: someone types 27AAPFU0993F1ZV. The 9 and 3 are swapped. Now the first 14 characters give P, not V. The check fails, and you know to look at the number again.
You do not have to do this by hand. The GSTIN Validator does it in your browser. The GSTIN you type is not sent anywhere.
What "invalid" means
The validator can fail a GSTIN for four reasons:
- Wrong length. A GSTIN has exactly 15 characters. Look for a missing or extra character.
- Wrong pattern. For example, a letter where the state code should be, or no Z in 14th place. This is often a mix-up between O and 0, or I and 1.
- Unknown state code. The first two digits are not a GST state or union territory code.
- Checksum digit does not match. Usually a typo in one character, or two characters swapped.
If a GSTIN fails, ask the business to send it again. Copy it from their invoice or registration certificate. Do not guess the fix.
What "valid" does not mean
A GSTIN that passes the check only fits together. The check cannot tell you:
- if the GST department issued this number at all,
- if the registration is active, cancelled or suspended, or
- whose name it is in.
Example: a supplier gives you a GSTIN on a bill for ₹50,000. It passes the check. But on the GST portal it shows "Cancelled" from last month. If you claim input tax credit on that bill, the credit can be denied.
To check, open Search Taxpayer on the GST portal. Type the GSTIN and the captcha. Look at the status, the legal name and the date of registration. If your supplier's registration may be cancelled, see automatic GST cancellation under Rule 20.
Quick checklist for a new supplier's GSTIN
- Check it with the GSTIN Validator.
- See that the state code matches the state on their address.
- See that the PAN inside it matches their PAN card, if you have it.
- Search it on the GST portal and check that it is Active.
- Check that the legal name on the portal matches the name on their invoice.
Sources
- stdnum.in_.gstin: GSTIN format and Luhn mod 36 check digit — python-stdnum
- Search Taxpayer — GST portal
This post is correct as of 19 November 2026. The checksum method is not in the CGST Act or Rules. We checked it against the sample GSTIN above and against open-source code. This is not legal or tax advice.