Browse all 103 browser-based tools (103 currently marked free), or tell us what useful utility we should build next.
Test a JavaScript regular expression against sample text. Adjust the pattern and flags to inspect which parts of the input match.
Input changes are debounced and run with a bounded Worker budget, so the editor stays responsive.
Every match is highlighted in place so you can see exactly what your pattern captures.
Read the match range, numbered $1 $2 groups, and named groups in a structured panel.
Matching uses your browser's native RegExp engine in a Worker when available, with byte, match, and time limits.
This tester evaluates patterns using your browser’s native RegExp engine, highlighting full matches, capture groups, and index positions across sample text. Regex syntax and matching behavior vary between engines. This tool follows the browser's JavaScript engine, so a pattern may behave differently in another language. Include matching, non-matching, empty, and long inputs before reusing a pattern in validation.
For responsive local work, keep patterns under 4 KB, test text under 128 KB, and within 10,000 matches. Input changes are debounced; matching can be cancelled and is stopped after a 2.5-second Worker budget. The no-Worker fallback accepts at most 32 KB of test text.
Build and debug a pattern in five steps. Changes are debounced before matching, and you can cancel a running job from the status row.
/ delimiters — no need to escape the slashes or wrap them yourself.gm (global + multiline); click any pill to add or remove it.[start-end] and any capture groups, shown as $1, $2, with named groups labeled.Paste any of these into the pattern field to start. Each is written for the JavaScript engine; treat the email and phone patterns as format checks, not strict standards validation.
^[^\s@]+@[^\s@]+\.[^\s@]+$Checks the basic [email protected] shape, not full RFC 5322 validity.
^https?:\/\/[^\s$.?#].[^\s]*$Matches links beginning with http:// or https://.
^\+?[\d\s-]{10,15}$Optional + prefix, 10–15 digits, spaces, or dashes.
(?<y>\d{4})-(?<m>\d{2})-(?<d>\d{2})Captures year, month, and day by name.
A regular expression is a compact language for describing patterns in text. The browser compiles your pattern with new RegExp(pattern, flags) and runs it against the test string — the same call your own JavaScript uses. This tool follows the JavaScript flavor defined in the ECMAScript RegExp specification, with per-feature behavior documented on MDN's RegExp reference.
Because the engine is JavaScript-specific, a few habits from other flavors do not carry over: there are no possessive quantifiers (a++) and no atomic groups. Modern ES2018 features do work here: named groups (?<name>...), lookbehind (?<=...) and (?<!...), and Unicode property escapes such as \p{L} when the u flag is on.
1. Capture PascalCase words (the default demo)
Pattern ([A-Z])\w+ with flags gm against PascalCase words like FunctionNames matches PascalCase, FunctionNames, and group $1 holds the leading capital (P, F).
2. Multiline anchors
Pattern ^\w+ on three lines returns one match per line with the m flag on. Remove m and you get a single match — the first word of the whole string only.
3. Edge case: the dot does not cross newlines
Pattern a.b against a\nb returns no match, because . excludes newlines by default. Add the s (dotAll) flag and it matches.
4. Failing literal: catastrophic backtracking
Pattern (a+)+$ against aaaaaaaaaaaaaaaaaaaaaaaaaaab can make a native engine do exponential work. The tester isolates that work in a time-bounded Worker when available and rejects this shape in its no-Worker fallback; flatten nested quantifiers before shipping a pattern to a server. Rewrite it as a+$.
The five flags below are exposed as toggle pills; the default state is gm. The y (sticky), d (hasIndices), and v (unicodeSets) flags exist in the spec but are not toggled here. Note that u and v are mutually exclusive and cannot be combined.
| Flag | Name | What it changes |
|---|---|---|
| g | global | Find all matches instead of stopping after the first. |
| m | multiline | ^ and $ match the start/end of each line, not just the whole string. |
| i | ignoreCase | Casing differences are ignored when matching. |
| s | dotAll | Lets . match newline characters too. |
| u | unicode | Treats the pattern as Unicode code points; enables \p{...} escapes. |
| Token | Description | Example Matches |
|---|---|---|
| . | Any character (except newline) | a, 1, % |
| \w | Word character | a-z, A-Z, 0-9, _ |
| \d | Digit | 0-9 |
| [abc] | Character set (a, b, or c) | a, b, or c |
| (?:...) | Non-capturing group (no $n slot) | groups without capturing |
| + | One or more quantifier | "a" or "aaaa" |
With the g flag on, this tester stops collecting after 10,000 matches and tells you it hit the cap, and reports the cap rather than collecting without bound. It also auto-advances lastIndex past zero-width matches (like (?:) or \b) so the loop cannot stall on an empty match — a classic bug in naive while (regex.exec(...)) code. Matching is sent to a Worker when available, and the parent can terminate it after the time budget; a no-Worker fallback rejects common nested-quantifier shapes before calling the native engine. You can cancel a running match from the status row, and large match lists are paginated instead of creating thousands of result cards at once.
Apply a tested pattern as a substitution
Diff CheckerCompare two strings line by line
Text SorterSort and dedupe matched lines
Case ConverterSwitch captured text between cases
JSON FormatterValidate data you extracted with regex
URL ParserBreak a URL into its parts
HTML Entity ConverterEncode/decode scraped markup
Word CounterCount words, characters, and lines
URL Slug GeneratorSlugify strings with clean rules
Cron Expression BuilderBuild schedules with field syntax
New to pattern syntax? Read the guides on the Toolk blog for a full regex cheat sheet and worked walkthroughs.
Last updated: September 23, 2026 · Runs 100% in your browser — no uploads, tool input is not sent to Toolk.
It runs your browser's native JavaScript engine per the ECMAScript RegExp specification, so results match production code exactly. Habits from other flavors will fail here: no possessive quantifiers like a++ and no atomic groups. Modern ES2018 additions do work — named groups (?<name>...), lookbehind, and \p{...} Unicode property escapes when the u flag is on.
The dot excludes newline characters unless you enable the s (dotAll) flag, so a.b finds nothing in a\nb until s is toggled on. Anchors have their own trap: without m (multiline), ^ and $ only bind to the start and end of the entire string rather than each line.
No. Matching happens locally on your browser's built-in RegExp engine, and neither the pattern nor the sample text is included in requests or analytics events. Once the page and its local worker are loaded, the tool does not need to send your input anywhere.
The tester checks the pattern and test-text byte limits before starting. Matching runs in a Worker when the browser supports it, stops after a wall-clock budget, and can be cancelled while you type. Browsers without Worker support use a main-thread fallback capped at 32 KB of test text and reject common nested-quantifier patterns instead of attempting an unbounded native call.