JSON Formatter
Pretty-print messy or minified JSON with 2-space indents.
Test a regular expression against your text and see every match highlighted and counted as you type. It uses the JavaScript regex engine, not PCRE.
Your browser is preparing the tool. It runs 100% locally.
Enter a regular expression, choose flags and type a test string. The tool highlights every match and shows how many there are, updating as you type. An invalid pattern shows the error. It uses the browser's JavaScript (ECMAScript) regex engine, so most patterns behave as expected, but advanced syntax can differ from PCRE, Python or .NET. It all happens in this tab, and nothing is uploaded.
This tool lets you build and check a regular expression interactively. You type the pattern and flags and a sample of text, and it marks every part of the text the pattern matches, with a running count of matches.
Use it while you build a regex to confirm it catches what you intend and nothing more, before the pattern goes into code. The live highlighting shows where it hits and where it misses.
The tool compiles your pattern and flags into a regular expression using the browser's built-in engine, then runs it against the test string. Each match is wrapped in a highlight, and the total is counted. If the pattern is not valid, the engine's error message is shown instead.
Because it uses the browser, the flavour is ECMAScript, the same regex your JavaScript code would run. Flags control behaviour: g matches all occurrences, i ignores case, m makes the anchors work per line, s lets the dot match newlines, u enables full Unicode, and y anchors matching to a position.
g match all occurrences (not just the first)
i ignore case m ^ and $ match per line
s dot matches newlines u full Unicode y sticky (match at a fixed position)pattern \b\w+@\w+\.\w+\b on text with two email addresses → 2 matches highlightedThis is the ECMAScript flavour. A pattern that works here matches the same way in JavaScript, but may differ in PCRE, Python or .NET if it uses advanced features.
Your pattern and test text stay on your device. The matching runs in your browser with no network request, so nothing is uploaded.
Because the work is local, you can test a pattern against real log lines or sample data without it being stored or sent anywhere.
The tool keeps nothing between sessions: close the tab and the pattern and text are gone.
The matching comes straight from the browser's regex engine, so what you see here is what your JavaScript code will produce.
The flavour is ECMAScript, not PCRE. If your pattern targets PHP, Python, .NET or a database, test it there too: named groups, lookbehind width, and several advanced constructs differ, and a pattern that works here can behave differently elsewhere.
Without the global flag, a regex matches only the first occurrence in code, though this tool highlights all of them for visibility. Keep the g flag in mind when you copy the pattern into your own code, where it changes how methods like match behave.
A complex or poorly written pattern can be slow on large inputs, and certain patterns can backtrack badly (catastrophic backtracking). The tool runs in your browser, so an extreme pattern on a big string may briefly hang the tab.
Develop and refine a regex with instant visual feedback.
See what a pattern catches and what it misses.
Check a pattern for emails, codes or IDs against samples.
Experiment with syntax and flags and watch the effect live.
If your regex runs in PHP, Python or .NET, test it in that engine too, since advanced syntax differs. For find-and-replace rather than just matching, use a tool or editor with a replace field. For very large inputs, run the pattern in your code with proper safeguards.
Runs your pattern with the browser's JavaScript (ECMAScript) regex engine and highlights matches as you type. Advanced syntax differs from PCRE, Python and other flavours.
Pretty-print messy or minified JSON with 2-space indents.
Paste JSON and find out whether it parses.
Standard Base64 for any text, emoji included.
MD5, SHA-1 and the SHA-2 hashes of any text, as you type.
Up to 500 random version 4 UUIDs at once.
Strips comments and whitespace to put a stylesheet on one line.
Paste, run and copy. The code stays in your browser and you don't need an account.