Regex Tester
JavaScript regular expressions with live matches.
Loading tool
Type a pattern, flip flags, and watch matches highlight in the sample. Invalid patterns show the engine error.
How to use this tool
- Paste the snippet. Drop JSON, code, or a token into the input. It is not sent to a server.
- Run the action. Format, decode, or generate. Parse errors stay on the page.
- Copy the output. Copy the result back into your editor or terminal.
Engine
This is the browser's JavaScript RegExp, including named groups and lookbehind where the engine supports them. It is not PCRE or .NET.
Frequently asked
Can I use /x comments?
No. JavaScript has no free-spacing flag.
Does it support recursive patterns?
No. Stay inside JS syntax.
Why did a greedy pattern freeze the tab?
Catastrophic backtracking can lock the engine. Keep samples short while you experiment.
Are replacements available?
A replace box uses the same pattern. For a full document, use Find and Replace.
Is my sample uploaded?
No.