Text & Comparison

Regex Tester

Run a JavaScript regular expression against sample text and inspect matches, positions, and captured groups.

Matches
Your result will appear here.
Processed locally in this browser. Your input is not sent to DevKitly.

What is Regex Tester?

Enter a pattern on the first line (as /pattern/flags or a bare pattern), a line containing ---, then the text to search. Every match is listed with its position and capture groups. The global flag is added automatically so all matches are found.

How to use Regex Tester

  1. Paste your input into the editor above, or select Sample to load an example.
  2. Select Test expression. If the input cannot be processed, a message explains what to fix.
  3. Use Copy or Download to take the result with you, and Clear to start again.

Example

Input

/(\d{4})-(\d{2})/
---
Releases: 2024-03, 2025-11

Output

#1 at index 10: "2024-03"
  groups: ["2024","03"]
#2 at index 19: "2025-11"
  groups: ["2025","11"]

Practical use cases

  • Debug validation patterns
  • Extract values from logs
  • Test search-and-match logic

Common problems

  • Forgetting expression flags
  • Using catastrophic backtracking patterns
  • Assuming regex syntax is identical in every language

Frequently asked questions

Which regex flavour is used?

JavaScript (ECMAScript). Syntax such as possessive quantifiers from PCRE is not supported.

Is Regex Tester free to use?

Yes. Regex Tester is free and does not require an account.

Does my input leave the browser?

No. This tool performs its processing locally in your browser and does not need to upload your input.