← All tools

Developer tools

Regex tester

Test JavaScript regular expressions with match positions, capture groups, and a time limit.

Loading tool…

Local processing. Maximum text input: 200,000 characters.

Result

HOW IT WORKS

01

Enter a pattern without surrounding slashes and choose flags.

02

Enter test text and run the test.

03

Review match positions and captured groups.

Worked examples

Enter the expression without / delimiters. Use g for all matches and i to ignore case. Capture groups are returned with each match. An empty match is advanced safely; a two-second timeout stops excessive backtracking.

Example Input / settings Expected result
Global word matching
[A-Za-z]+ · g
Hello 2026, Wei2!
[{"index":0,"text":"Hello","groups":[],"namedGroups":null},{"index":12,"text":"Wei","groups":[],"namedGroups":null}]
Named capture group
(?<year>\d{4}) · g
Year 2026
[{"index":5,"text":"2026","groups":["2026"],"namedGroups":{"year":"2026"}}]

Rules and limits

Uses your browser’s JavaScript regex engine. Match positions are zero-based UTF-16 offsets. Global mode lists up to 500 matches. Tests run in a worker and stop after two seconds; syntax differs from PCRE and Python.

A FEW HELPFUL ANSWERS

Before you get started.

Is my input uploaded?

These tools process your input in your browser. Input is not saved to a server or browser storage. Copy or download any result you want to keep.

Feedback