An open API service indexing awesome lists of open source software.

https://github.com/tk120404/gst

GSTIN regex and GST checksum validation. Verify/Validate the gstin number using the regex and checksum functions available in various programming languages
https://github.com/tk120404/gst

checksum checksum-validator gst gst-validator gstchecksum gstin india javascript python regex validation

Last synced: 15 days ago
JSON representation

GSTIN regex and GST checksum validation. Verify/Validate the gstin number using the regex and checksum functions available in various programming languages

Awesome Lists containing this project

README

        

# GSTIN regex and its checksum

GSTIN regex

### `\d{2}[A-Z]{5}\d{4}[A-Z]{1}[A-Z\d]{1}[Z]{1}[A-Z\d]{1}`

![](https://i.stack.imgur.com/YdvSA.png)

#### Format details

* First 2 digits of the GST Number will represent State Code as per the Census (2011).
* Next 10 digits will be same as in the PAN number of the taxpayer.
* First five will be alphabets
* Next four will be numbers
* Last will be check code
* The 13th digit will be the number of registration you take within a state i.e. after 9, A to Z is considered as 10 to 35 .
* 14th digit will be Z by default.
* Last would be the check code.

How to decode the [GST CheckSum](https://medium.com/@dhananjaygokhale/decoding-gst-number-checksum-digit-1ef2c8c53ad6)

* [Javascript checksum verification](https://github.com/tk120404/gst/blob/master/gstChecksum.js)
* [Python Checksum verification](https://github.com/tk120404/gst/blob/master/gstChecksum.py)
* [Swift Checksum verification](https://github.com/tk120404/gst/blob/master/gstChecksum.swift)