regex · v1

Regex Tester

Test JavaScript regular expressions locally in your browser, with matches, indices, capture groups and automatic timeout.

Run now

Sample input

/(\d+)/g
Order 1024, item 7

Browser-local execution

The input stays on this device. No upload, REST endpoint, or MCP call is used.

Usage and examples

Open the workbench, put /pattern/flags on the first line and the text on subsequent lines, then run. A bare pattern defaults to g; g finds multiple matches, i ignores case, m enables multiline anchors, and u enables Unicode. JSON results contain matches, zero-based UTF-16 indices and capture groups. Input is limited to 10,000 UTF-16 code units and patterns to 256. An isolated Worker is terminated after 1 second, with at most 200 matches and 64 KiB of results. Text is processed only in your browser.

Example 1

Input
/(\d+)/g
Order 1024, item 7
Parameters
{}
Expected output
{
  "matches": [
    {
      "match": "1024",
      "index": 6,
      "groups": [
        "1024"
      ]
    },
    {
      "match": "7",
      "index": 17,
      "groups": [
        "7"
      ]
    }
  ],
  "truncated": false
}

Who it is for

Use Regex Tester for browser-local processing. The input stays on this device.

Notes

Open the workbench, put /pattern/flags on the first line and the text on subsequent lines, then run. A bare pattern defaults to g; g finds multiple matches, i ignores case, m enables multiline anchors, and u enables Unicode. JSON results contain matches, zero-based UTF-16 indices and capture groups. Input is limited to 10,000 UTF-16 code units and patterns to 256. An isolated Worker is terminated after 1 second, with at most 200 matches and 64 KiB of results. Text is processed only in your browser.

Frequently asked questions

What does Regex Tester do?

Test JavaScript regular expressions locally in your browser, with matches, indices, capture groups and automatic timeout.

How do I use Regex Tester online?

Click “Open workbench” to open Regex Tester, provide your input, and run the tool.

What input and output does Regex Tester use?

Declared input type: text. Declared output type: text.

Does Regex Tester upload my input?

Regex Tester processes input locally in your browser on this device, without uploading it for execution.