Q QWIK INVOICE
Q QWIK INVOICE

GSTIN Format Explained: A 15-Digit Breakdown

Written by Naresh, Founder of QWIK INVOICE · Last updated: 25 September 2026

A GSTIN is always exactly 15 characters, and every position means something specific — it's not a random ID. The first two digits are a state code, the next ten are the business's PAN, and the last three characters encode a registration count and a checksum. Once you know the pattern, you can spot an obviously malformed GSTIN at a glance.

What does each position in a GSTIN represent?

PositionRepresentsExample
1–2State code"27" = Maharashtra, "29" = Karnataka, "07" = Delhi, "33" = Tamil Nadu
3–12The business/proprietor's 10-character PANe.g. "AAAAA0000A"
13Entity code"1" for the first registration under that PAN in that state, "2" for a second, and so on
14ReservedCurrently always "Z"
15Checksum digitComputed via a check-digit algorithm to catch typos

Put together, a GSTIN like 27AAAAA0000A1Z5 reads as: state code 27 (Maharashtra), PAN AAAAA0000A, first registration under that PAN in that state (1), the reserved "Z," and a checksum digit. State codes follow the Census 2011 numbering list — the examples above are illustrative of well-known states; always confirm the specific code against the official GST portal rather than assuming from memory, since getting the state code wrong is a real source of invoicing errors.

GST state code list (first two digits of a GSTIN)

These are the two-digit codes in use today. Union territories without their own legislature (Chandigarh, Lakshadweep, Andaman and Nicobar, Dadra and Nagar Haveli and Daman and Diu, and Ladakh) charge UTGST in place of SGST, but their GSTIN state code works the same way.

CodeState / UTCodeState / UT
01Jammu and Kashmir21Odisha
02Himachal Pradesh22Chhattisgarh
03Punjab23Madhya Pradesh
04Chandigarh24Gujarat
05Uttarakhand26Dadra and Nagar Haveli and Daman and Diu
06Haryana27Maharashtra
07Delhi29Karnataka
08Rajasthan30Goa
09Uttar Pradesh31Lakshadweep
10Bihar32Kerala
11Sikkim33Tamil Nadu
12Arunachal Pradesh34Puducherry
13Nagaland35Andaman and Nicobar Islands
14Manipur36Telangana
15Mizoram37Andhra Pradesh
16Tripura38Ladakh
17Meghalaya97Other Territory
18Assam99Centre Jurisdiction
19West Bengal
20Jharkhand

Codes 25 (old Daman and Diu) and 28 (Andhra Pradesh before Telangana was carved out) are retired, so you may still see them on very old registrations. Telangana (36) and Andhra Pradesh (37) are the pair people most often mix up when reading a GSTIN by eye.

Why does the state code actually matter for invoicing?

Because it's how the tax split gets decided. Comparing the first two digits of your GSTIN against your customer's GSTIN tells you immediately whether a sale is intra-state (same state code — charge CGST + SGST) or inter-state (different state codes — charge IGST). See CGST vs SGST vs IGST Explained for the full rule and worked examples — this is exactly the check that QWIK INVOICE's invoice generator runs automatically the moment you enter a GSTIN.

What does the PAN embedded in a GSTIN mean for the business structure?

Since a GSTIN is built directly around a PAN, the same PAN can hold more than one GSTIN — most commonly when a business has registrations in multiple states, or multiple registrations within one state for separate business verticals. That's exactly what the 13th character (entity code) is for: it distinguishes multiple registrations sharing the same underlying PAN, rather than each one needing an unrelated ID.

How is the GSTIN checksum digit calculated?

The 15th character is a check digit computed from the first 14, so a single mistyped character is almost always caught. The method, in five steps:

  1. Map each of the first 14 characters to a number: digits 0–9 stay as they are, letters A–Z become 10–35.
  2. Multiply every character's value by 1 or 2, alternating, starting with 1 on the first character.
  3. For each product, divide by 36 and add the quotient and the remainder together.
  4. Add up all 14 results.
  5. The check digit is the character for (36 − (sum mod 36)) mod 36.

Worked through on the sample GSTIN 27AAPFU0939F1ZV, the 14 values add up to 221. Since 221 mod 36 = 5, the check value is 36 − 5 = 31, and 31 is the letter V, which is exactly the last character. A GSTIN whose 15th character doesn't match this calculation is mistyped or invalid. Passing the checksum only proves the number is well-formed, not that it is registered, so an active-status check on the GST portal is still needed.

How do I spot an obviously invalid GSTIN?

  • Wrong length — anything other than exactly 15 characters isn't a valid GSTIN.
  • Wrong character types in the wrong positions — positions 1–2 and 13 should be numeric/alphanumeric per the pattern above, not arbitrary letters; the PAN block (positions 3–12) follows the standard 5-letters/4-digits/1-letter PAN pattern.
  • State code that doesn't exist — if the first two digits aren't in the state code list above, the whole number is suspect.
  • A checksum that doesn't match — run the calculation in the checksum section above (or simply use the GST portal's verification tool) rather than eyeballing it.

The reliable way to confirm a GSTIN is genuinely valid — not just correctly formatted — is the official GSTIN search tool on the GST portal, which also confirms the registration is active and shows the registered legal name. It's worth doing this for any new B2B customer before you invoice them, especially since an invoice built on a wrong or inactive GSTIN can cause problems for their input tax credit claim, not just yours.

This guide is general information, not tax advice. Confirm specifics with a qualified tax professional or chartered accountant, or the GST portal / CBIC directly, before relying on it.

Frequently asked questions

How many characters does a GSTIN have?

Exactly 15 — 2 for the state code, 10 for the PAN, 1 entity code, 1 default "Z" character, and 1 checksum digit. Any string longer or shorter than 15 characters, or one that doesn't fit this pattern, is not a valid GSTIN.

Is the PAN inside a GSTIN the business's PAN or the owner's personal PAN?

It depends on the business structure. For a proprietorship, the business's GSTIN embeds the proprietor's personal PAN, since a sole proprietorship doesn't have a separate legal PAN. For a company, LLP or partnership, it embeds that entity's own registered PAN.

Can the same PAN have more than one GSTIN?

Yes — a single PAN can hold multiple GSTINs, either because the business has separate registrations in different states, or multiple registrations within the same state for different business verticals. The 13th character (entity code) is exactly what distinguishes these multiple registrations under the same PAN.

What is the GST state code for Telangana and Andhra Pradesh?

Telangana is 36 and Andhra Pradesh is 37. Code 28 was Andhra Pradesh before Telangana was created, so it only appears on very old registrations. Ladakh is 38, Maharashtra is 27, Karnataka is 29, Delhi is 07 and Tamil Nadu is 33.

How is the 15th character (checksum) of a GSTIN calculated?

Each of the first 14 characters is turned into a number (0–9 stay, A–Z become 10–35), multiplied by 1 or 2 alternately, divided by 36, and the quotient and remainder are added. The total is taken mod 36 and subtracted from 36 (mod 36) to give the check character. A mismatch means the GSTIN is mistyped or invalid; a match only proves it is well-formed, not that it is registered.

How do I check if a customer's GSTIN is real and active before invoicing them?

Use the official GSTIN search/verification tool on the GST portal — it will confirm whether the number is valid, active, and shows the registered legal name, which you can cross-check against what the customer gave you. This takes under a minute and is worth doing for any new B2B customer before you rely on their GSTIN for the CGST/SGST/IGST split.

Ready to put this into practice?

Create Your Invoice Free