Regex tester
JavaScript RegExp syntax. Enter a pattern and flags, then subject text. Enable replace to preview substitutions. Invalid patterns show a syntax error.
Regex notes
JavaScript regex differs from PCRE or POSIX. Lookbehind is supported in modern browsers. Very large subjects or catastrophic backtracking can freeze the tab — start with small samples.