Development
Regular expression lab
Inspect matches and captures, generate verified examples, and draw an SVG syntax diagram.
Ready when you are
01
Add your contentPaste text or try a sample
02
Choose an actionClear options. Predictable results.
03
Take it with youCopy, download and carry on
Using this tool
Inspect JavaScript regex matches, offsets, and capture groups to debug patterns.
Actions: Process
Example
In the dedicated test field enter a12 b3, use pattern \d+ without slashes and flag g, then Find matches.
Example action and settings
Action: Match Pattern: \d+ Flags: g Count: 5
Input / action
a12 b3
Result / expected behavior
{
"matches": [
{
"match": "12",
"index": 1,
"end": 3,
"captures": [],
"groups": {}
},
{
"match": "3",
"index": 5,
"end": 6,
"captures": [],
"groups": {}
}
],
"count": 2,
"truncated": false
}Scope and limitations
- Uses JavaScript regex semantics; browser worker computation stops after 1.5 seconds and returns at most 10,000 matches.
Common mistakes
- Do not enter /pattern/g delimiters; without g only the first match is returned, and offsets use UTF-16 units.
Related tools
Regex syntax reference Text diff
Privacy and browser support
Input is processed in this browser. Do not use real keys or active sensitive credentials as demonstration data. Device features require browser support and your permission.