Shridha/ tools

Regex Tester

Type a pattern and some text. Matches are highlighted as you type, and each match is listed with its position and capture groups.

Without the slashes, in JavaScript syntax.

3 matches

Invoice dated 2026-10-20, due 2026-11-19.
Paid on 2026-11-02.
  1. 2026-10-20 at position 14Groups: 1=20262=103=20
  2. 2026-11-19 at position 30Groups: 1=20262=113=19
  3. 2026-11-02 at position 50Groups: 1=20262=113=02

How it works

Enter the pattern without the surrounding slashes. It uses JavaScript regular expression syntax.

The flags change how it matches: g finds every match, i ignores upper and lower case, m makes ^ and $ match at each line, and s lets a dot match a new line.

Parts of the pattern inside brackets are capture groups. Each match lists what every group captured.

If the pattern is not valid, the error is shown instead of the results.

Good to know

Different languages have slightly different regex features. A pattern that works here may need small changes in Python, Java or PHP.

Some patterns can be very slow on certain text. If the page freezes, simplify the pattern.

Frequently asked questions

Which regex flavour is this?

JavaScript, the one your browser runs.

Why does it stop at 500 matches?

To keep the page quick. Narrow the text or pattern to see the rest.

Is my text sent anywhere?

No. The pattern is run in your browser.

Related tools