🔍

Regex Tester

Test JavaScript regular expressions and see matches and capture groups

Test a regular expression

Try a JavaScript-flavored regular expression against sample text and see every match, its position, and any capture groups. Toggle the common flags. Everything runs locally in your browser using the native regex engine.

FAQ

Which regex flavor is this?

JavaScript (ECMAScript) regular expressions — the same engine your browser uses, so results match what runs in your JS code.

What do the flags do?

g finds all matches, i is case-insensitive, m makes ^/$ match line starts/ends, and s lets . match newlines.

Does it show capture groups?

Yes. Each match lists its numbered capture groups so you can confirm what your parentheses capture.