For when a pattern should match and doesn't.
This page names the character where matching stopped, and
what the pattern wanted there versus what is actually in the way.
Then it changes one flag, or one detail of the input, and runs the real engine again
to show you the single fix that works.
Fullwidth characters, zero-width characters and CRLF line endings (\r) are checked too.
The string you expect it to match (newlines are fine)
The top row is your test string, the bottom row is the pattern. Green is what got through, red is where it stopped. The red in the pattern is the part that was waiting.
The pattern is grown one piece at a time and each prefix is
run through the browser's own RegExp.
Where ✓ turns into ✗ is where the pattern outran the input.
This is a completely different method from "how far it got" above,
so if both point at the same place, you can trust it.
Each row is one single change to a flag or to the input, re-run through the real engine. Only changes that actually made it match are listed — these are measurements, not guesses.
Characters that are hard to spot by eye: fullwidth letters and symbols, no-break spaces,
zero-width characters, a BOM, \r, and variation selectors.
To report where matching stopped, this page runs its own matcher.
Its answers — whether it matches, where the match starts and ends, and what each group captured —
are compared against the browser's RegExp right here, every time you type.
If they ever disagree, a ✗ appears in this box. Check it before you believe the diagnosis above.
| branch was tried at the same position and all of them failed.
In that case every candidate is listed.RegExp. Only the ones that actually matched are shown.(a+)+$ explodes combinatorially the
moment it fails. When the limit is hit, the trace stops and says so, with the step count
— being cut off is itself the diagnosis.\p{...} and the set operations of the v flag
are not handled by the built-in matcher. For those patterns, "where it stopped" is skipped and
the diagnosis relies on the browser alone (the self-check reports them as out of scope).(?<=…) is matched
backwards, as the specification describes. The first version approximated it by scanning
for a start position from the left; comparing 7,697 cases against the browser turned up
3 where the captured groups differed, all from that approximation. It was rewritten.