Live visual feedback
Matched ranges are highlighted beside the source text, while zero-length matches receive a visible position marker.
Build, debug and save regular expressions with timeout-protected live matching, exact positions, capture groups and replacement previews.
Live highlights, safe execution, replacement testing and persistent sessions
$& whole match$1 numbered group$<name> named group$$ literal dollarReplacement uses the selected flags. Without the global flag, only the first applicable match is replaced; sticky mode must also begin at the selected start index.
Use the tester to inspect what a regular expression actually matches, where each match starts and ends, which capture groups are populated, and how a replacement template changes the text.
Matched ranges are highlighted beside the source text, while zero-length matches receive a visible position marker.
Each result includes its index, end position, line, column, value, numbered groups and available named groups.
Tests run away from the interface and are stopped when they exceed the chosen execution limit, reducing the risk of a frozen page.
Preview standard replacement tokens before moving a pattern into application code, an editor or a server workflow.
Keep multiple patterns and test documents organized locally, then rename, duplicate, export, import or delete them.
Copy a regex literal or download match reports, replacement output and validated session data with prefixed filenames.
Follow the same workflow shown by the controls in the testing workspace.
Type the regular-expression pattern without slash delimiters, then select the flags required by the test.
Paste text, load a preset, or import a supported UTF-8 text file into the test-text editor.
Run the test or keep live testing enabled to inspect highlighted matches, positions, capture groups and performance details.
Enter a replacement template and review the resulting text before copying or downloading it.
Keep named sessions on the current device, export a session file, or download match results for later review.
Common building blocks for browser-based regular expressions. Exact advanced-feature support depends on the current browser.
| Pattern | Meaning | Example use |
|---|---|---|
. | Any character except a line terminator unless dot-all mode is enabled | a.c |
\d / \D | Digit / non-digit | \d{4} |
\w / \W | Word character / non-word character | \w+ |
\s / \S | Whitespace / non-whitespace | \s+ |
[abc] | One character from a set | [A-F0-9] |
[^abc] | One character not in a set | [^,\r\n]+ |
^ / $ | Start / end boundary, affected by multiline mode | ^\w+$ |
* + ? | Zero or more, one or more, zero or one | https? |
{m,n} | Minimum and maximum repetition | \d{2,4} |
(...) | Numbered capture group | (\w+)@ |
(?<name>...) | Named capture group | (?<year>\d{4}) |
(?:...) | Non-capturing group | (?:cat|dog) |
x|y | Alternative | yes|no |
(?=...) / (?!...) | Positive / negative lookahead | \w+(?=:) |
\b | Word boundary | \bword\b |
A timeout stops a long-running browser test, and the match limit controls result volume. Neither feature proves that the expression will be efficient in production or on much larger input.
The tester follows current browser syntax. Patterns copied from another language may require different escaping, flags, anchors, Unicode handling or replacement tokens.
The page has no tool-specific regex-processing endpoint. Test text, replacement content and session exports are produced in the current browser.
Remember sessions stores pattern and text data for this website on the current device. Disable it or clear saved data before using a shared computer.
Review the highlighted error message, unmatched parentheses, character classes, backslashes and unsupported constructs.
Reduce the text size, lower ambiguous nesting, replace broad repeated groups, or test smaller portions of the expression.
Check case sensitivity, anchors, line mode, start index, escaping and whether sticky mode requires a match at the exact current position.
Confirm Remember sessions is enabled and that browser storage is available. Private browsing may clear data after the private session ends.
Use the download actions when clipboard access is unavailable. Copy operations generally work best on a secure HTTPS page.
Save it as UTF-8 text, remove binary content, and keep the file below 2 MB and 300,000 decoded characters.
Answers about flags, highlighting, capture groups, replacement strings, timeout protection, sessions, imports and privacy.
It is a browser-based regular-expression workspace with live highlighting, match details, capture groups, replacement preview, timeout protection and named sessions.
Yes. Live testing is enabled by default and runs after a short typing delay. You can pause live testing and use the Run Test button manually.
No. Enter only the pattern body. Select flags separately using the flag controls beside the pattern.
The page exposes the flags supported by the current browser, including global, case-insensitive, multiline, dot-all, Unicode, Unicode sets, sticky and match-index modes where available.
A disabled flag is not supported by the current browser, or it conflicts with another selected mode. Unicode and Unicode-sets modes cannot be active together.
Global mode continues searching after the first match so the tester can collect every non-overlapping match up to the selected result limit.
Sticky mode requires a match to begin exactly at the current search position. It is useful for tokenizers and parsers that advance through text in a controlled sequence.
When supported, match-indices mode exposes exact start and end positions for the whole match and capture groups. The tester may also use it internally for accurate highlighting.
Yes, when the current browser supports them. Named groups appear beside numbered capture groups in the match details.
Lookahead is broadly supported. Lookbehind depends on the current browser, so a pattern may be rejected when that syntax is unavailable.
No. The tester follows the regular-expression syntax implemented by current web browsers. Some PCRE, Python, Java and .NET constructs have different syntax or are unavailable.
A zero-length match is shown as a small position marker because there is no character range to color. Its exact index remains visible in the match list.
Ordinary matching returns non-overlapping results according to browser regular-expression behavior. Overlapping matches usually require a lookahead-based pattern.
Pattern execution runs away from the main interface and is stopped when it exceeds the selected timeout. A new test also cancels the previous run.
No. It limits one browser test, but production performance depends on input size, runtime, pattern structure and surrounding application logic.
It is excessive repeated searching caused by certain ambiguous nested patterns. The page warns when a test times out, but developers should still simplify risky expressions.
You can choose a practical limit from 100 to 10,000 matches. The tester stops collecting at that limit to protect responsiveness.
The workspace accepts up to 300,000 characters. Imported files must be 2 MB or smaller and decode as UTF-8 text.
You can import UTF-8 TXT, LOG, JSON, CSV, Markdown, XML, HTML and source-code text files. Binary content is rejected.
Yes. Enter a replacement template and the page produces a live replacement result using the selected pattern and flags.
Yes. Standard replacement tokens such as the whole match, numbered captures and named captures work when supported by the current browser.
Yes. Copy Regex copies a slash-delimited representation with escaped slash characters and the currently selected flags.
Yes. The page can download a prefixed TXT report or CSV file containing match numbers, positions, values and capture-group information.
Named sessions remember the pattern, flags, test text, replacement and settings on this device so you can return to them after closing the page.
When Remember sessions is enabled, sessions are saved in browser storage for this website. They are not sent to a tool-specific server endpoint.
Yes. Turn off Remember sessions on this device. The page removes its stored session data while keeping the current in-memory workspace available until the tab closes.
Yes. Export Session creates a JSON file, and Import Session restores a compatible session file after validation.
Yes. After confirmation, the named session is removed from the in-memory list and from browser storage when session saving is enabled.
This page has no tool-specific upload or regex-processing endpoint. Typed and imported content is processed in the current browser.
The regex workspace does not require an external processing service or page-specific dependency. Shared website resources may still load normally.
Current stable Chrome, Edge, Firefox and Safari support the core tester, local sessions, text import, copy and download workflows. Individual regex features depend on browser support.
Regular-expression flavors differ. Flags, Unicode handling, anchors, replacement tokens and advanced constructs can vary between browsers, servers, editors and programming languages.
Continue with active developer, text, SEO, validation and recently completed CorrectionCopy tools.
Generate gradients, layered box shadows and border radius with live previews and code.
Open ToolTurn syntax-highlighted code into polished images with frames and social presets.
Open ToolGenerate meta tags, preview social cards and analyze keyword density and content signals.
Open ToolWrite and preview Markdown with shortcuts, document checks, import and HTML export.
Open ToolConvert Chinese text for Simplified, Taiwan Traditional and Hong Kong usage.
Open ToolValidate IBAN country format, length and MOD-97 checksum, then format it correctly.
Open ToolCount words, characters, sentences and reading statistics.
Open ToolCreate editable privacy-policy and terms templates for websites, stores, SaaS and apps.
Open ToolAdd top, bottom or freely positioned meme text to images and download the result.
Open ToolCreate ICO, PNG, Apple touch and PWA icons with manifest and ZIP downloads.
Open ToolBatch convert WebP to JPG or JPEG and SVG to PNG with resizing and quality controls.
Open ToolDraw or type a signature, customize its style and download a transparent PNG.
Open ToolCalculate ratios, missing dimensions and crop or contain sizes for images and video.
Open ToolPick exact colors, extract palettes and inspect HEX, RGB, HSL and contrast values.
Open ToolDraw, type or upload a signature, place it on any PDF page and download the signed file.
Open ToolLocate stuck pixels and run a targeted rapid color cycle over the affected area.
Open Tool