Regex Matcher Online – Find All Matches
Find all JavaScript regex matches online, inspect indexes and capture groups, and test patterns locally without uploading your text.
Regular Expressions topic hub
Test and debug JavaScript regular expressions, inspect matching and capture groups, practice replacements, and find practical fixes for common pattern errors.
Start by testing a pattern against sample text, then check flags, anchors and capture groups. Use the troubleshooting examples when a match fails or a replacement behaves unexpectedly, and the guide for syntax reference.
Recommended starting points
4 resources
Find all JavaScript regex matches online, inspect indexes and capture groups, and test patterns locally without uploading your text.
JavaScript regex quick reference for character classes, anchors, quantifiers, groups, lookarounds, flags, replacements, and copyable examples.
Test JavaScript regular expressions locally, validate pattern and flags, and see whether sample text matches without uploading logs or snippets.
Troubleshoot JavaScript regular-expression syntax, flags, anchors, quantifiers, groups, lookarounds, matching behavior, and replacements.
Start here
2 resources
Test JavaScript regular expressions, inspect all matches and capture groups, or replace text locally in your browser with configurable regex flags.
Replace text with JavaScript regular expressions locally, preview capture-group replacement tokens, and control single or global replacement with regex flags.
Troubleshoot
24 resources
Understand why a JavaScript regex with * can match zero characters and use + when at least one occurrence must be present.
Fix JavaScript regex alternation precedence by grouping alternatives before applying ^ and $ anchors or shared surrounding context.
Fix a JavaScript regex that ends with a lone backslash by completing or removing the unfinished escape sequence.
Test JavaScript regex capture groups locally and inspect every numbered capture, match value, and zero-based match index in structured output.
Make a JavaScript regex case insensitive with the i flag when uppercase or lowercase text should match the same pattern.
Use JavaScript regex dotAll mode when . must match across line terminators, and compare the same pattern with and without the s flag locally.
Fix duplicate JavaScript regex flags such as gg or ii by keeping each flag at most once before compiling the pattern.
Escape a dot in JavaScript regex syntax when you need a literal period, not the . wildcard, and test the corrected pattern locally.
Compare greedy and lazy JavaScript regex quantifiers locally when .* consumes more text than intended, using Match All to inspect the difference.
Fix an unsupported JavaScript regex flag by using only browser-supported RegExp flags such as g, i, m, s, u, v, y, or d.
Fix a JavaScript regex quantifier such as {3,2} when its minimum repeat count exceeds its maximum count.
Make a JavaScript regex match the entire string instead of a substring by adding ^ and $ anchors, then test the exact-match behavior locally.
Use the JavaScript regex m flag when ^ and $ should match the start and end of individual lines in multiline text.
Test JavaScript named capture groups locally and inspect both numbered captures and the named groups object returned for each regex match.
Test JavaScript negative lookahead (?!...) locally to match a token only when an unwanted pattern does not immediately follow it.
Use a JavaScript regex non-capturing group (?:...) to group alternatives or quantifiers without adding an unnecessary numbered capture.
Fix JavaScript regex Nothing to repeat errors caused by *, +, ?, or repetition syntax without a preceding token.
Test JavaScript positive lookahead (?=...) locally to require following text without including that following text in the regex match.
Fix a JavaScript regex character range such as [z-a] when the range endpoints are reversed, then retest the corrected class locally.
Compare first-match and replace-all JavaScript regex behavior locally by adding the global g flag to the same pattern and replacement.
Preview JavaScript regex replacement with capture-group tokens such as $1 and $2 locally, using the exact String.replace behavior of the browser.
Fix an unterminated JavaScript regex character class by closing an opening bracket and retest the corrected pattern locally.
Fix an unclosed JavaScript regex group by finding an opening parenthesis without a matching close, then test the corrected pattern locally.
Use JavaScript regex word boundaries when a token should match as a word but not as part of a longer identifier or sentence word.