Find a tested regular expression for the format you need, copy it for JavaScript, Python, Java, C# or PHP, and try it on your own values right on the page. Indian formats sit next to the usual ones: mobile numbers with +91, PAN, GSTIN, IFSC, PIN codes, Aadhaar format, vehicle registration numbers, UPI IDs and amounts with Indian commas. Every pattern comes with examples it accepts and rejects.
Indian mobile number
Ten digits starting with 6, 7, 8 or 9, with an optional +91, 91 or 0 in front and an optional space or dash in the middle.
/^(?:\+91[\-\s]?|91|0)?[6-9]\d{4}[\-\s]?\d{5}$/re.compile(r'^(?:\+91[\-\s]?|91|0)?[6-9]\d{4}[\-\s]?\d{5}$')"^(?:\\+91[\\-\\s]?|91|0)?[6-9]\\d{4}[\\-\\s]?\\d{5}$"'/^(?:\+91[\-\s]?|91|0)?[6-9]\d{4}[\-\s]?\d{5}$/'9876543210matches+91 98765 43210matches+91-9876543210matches09876543210matches919876543210matches5876543210does not match98765 4321does not match+1 9876543210does not match98765432100does not matchTesting runs in your browser. What you type never leaves this device.
40+ patterns in seven groups, with Indian formats first
Each pattern tested against examples that should and should not match
Copy as JavaScript, Python, Java/C# string or PHP
Try your own values: pass or fail per line, or highlighted matches
Plain notes on what each pattern does not check
Runs in your browser
Check a mobile number, PIN code or PAN as the customer types, before the form is sent.
Find rows with a badly formatted GSTIN or IFSC in exported data.
Pull OTPs, hashtags, @mentions or UTM tags out of text.
A regex checks shape: ten characters in the PAN layout, or fifteen in the GSTIN layout. It cannot tell whether the number was issued. GSTIN and Aadhaar end in a check character that needs a small piece of code to verify, and card numbers need the Luhn check. The descriptions say where this applies.
Adjust a pattern and test it with full match details in the regex tester. To pull phone numbers or emails out of a document, try extract phone numbers or extract emails.
Regex Tester
Test regular expressions
Regex Escape
Escape special characters so text matches literally in a regex
Regex Match Extractor
Pull every regex match or capture group into a list, CSV or JSON
Extract Phone Numbers
Pull phone numbers, emails or links out of text, normalised to +91 and deduped, with CSV export
JSON Formatter
Format and validate JSON
JSON Sort Keys
Alphabetize JSON keys at every level
JSON Flatten
Nested JSON to dot-path keys
JSON Unflatten
Dot-path keys back to nested JSON
Built by Edesy
Edesy builds AI products for Indian businesses. Start self-serve, no demo call needed.
AI agents that answer and make phone calls 24/7. Handle appointments, inquiries and support in Indian and global languages.
₹50 free credit. No demo call needed.