Regex Tester
Write a regular expression and see every match highlighted as you type.
- Runs in your browser — nothing uploaded
- Instant, no waiting in a queue
- Free, no watermark, no daily limits
Type a pattern and test string to see matches highlighted live, with capture groups and named groups listed for each match. Toggle the g, i, m, s, u and y flags, start from presets for emails, URLs, phone numbers, dates, hex colors and IPv4 addresses, and preview string.replace() output. Patterns run in an isolated worker, so a runaway pattern is stopped instead of freezing the page.
How to Test a Regular Expression
- 1
Enter a pattern
Type your regular expression or pick a preset, and toggle the flags you need.
- 2
Add test text
Paste the text to search. Matches are highlighted instantly and listed with their groups.
- 3
Preview a replacement
Turn on Replace to see the result of string.replace() with $1, $& or $<name> references.
Why use ToolzBank Regex Tester?
- Live match highlighting
- Capture groups and named groups
- All JavaScript flags: g, i, m, s, u, y
- Replace preview with $1, $& and $<name>
- Presets for common patterns
- Protection against catastrophic backtracking
Frequently asked questions
Which regex flavor does this use?
Why is only one match highlighted?
What happens if my regex is too slow?
Is my text sent anywhere?
More free developer tools
JSON Formatter & Validator
Beautify, minify & validate JSON
JSON to CSV
Flatten JSON arrays into CSV/Excel
XML Formatter
Pretty-print & validate XML
JWT Decoder
Decode & verify JSON Web Tokens locally
Timestamp Converter
Unix epoch ⇄ human-readable dates
Diff Checker
Compare two texts line by line
Base64 Encoder / Decoder
Encode & decode Base64 text and files
URL Encoder / Decoder
Percent-encode, decode & parse URLs
HTML, CSS & JS Formatter
Beautify HTML, CSS & JS; minify HTML & CSS
Hash Generator
MD5, SHA-1, SHA-256 & SHA-512 for text or files
Number Base Converter
Binary, octal, decimal & hex conversion
PX to REM Converter
Convert px ⇄ rem, or a whole stylesheet
Color Converter
HEX, RGB, HSL, HSV & CMYK with contrast check
YAML to JSON Converter
Convert YAML ⇄ JSON with error lines
SQL Formatter
Beautify SQL for MySQL, PostgreSQL & more
Markdown Editor
Write visually, download a .md file
