Skip to content
POST /api/v1/test-regex

Regex Tester

Enter a regex pattern and test text to see all matches, captured groups, and their positions. Supports case-insensitive, multiline, dotall, and unicode flags. Great for validating patterns before using them in code.

string required

Without delimiters (e.g. ^[a-z]+$)

string required
advanced options
string

i=case-insensitive, m=multiline, s=dotall, u=unicode

boolean

Find all matches, not just the first

X-Sandbox-Remaining: - get an api key

returns

data.matches
Each match with its text, groups, index and length.
data.is_match
True when the pattern matched at least once.
data.match_count
Number of matches found.
data.execution_time_ms
How long the match took, in milliseconds.
response awaiting request sending
Fill in the fields and send a request. The response lands here.

Run it from your code

A temporary key takes one request and lasts seven days at 20 calls a day. Register and it becomes 75 a day, still free.

$ curl -sX POST "https://apixies.io/api/v1/test-regex" \
    -H "X-API-Key: $APIXIES_KEY" \
    -H "Content-Type: application/json" \
    -d '{"pattern":"(\\w+)@(\\w+)\\.(\\w+)","text":"..."}' | jq '.data.matches'

questions

Do I need to include delimiters?

No. Enter just the pattern without / delimiters. The API adds them automatically. For example, enter ^[a-z]+$ instead of /^[a-z]+$/.

What flags are supported?

Four flags: i (case-insensitive), m (multiline, ^ and $ match line boundaries), s (dotall, . matches newlines), and u (unicode mode).

Is there protection against slow patterns?

Yes. The regex engine has a backtracking limit to prevent ReDoS (Regular Expression Denial of Service) attacks. Patterns that cause excessive backtracking return an error instead of hanging.

cookies

We use analytics cookies to see how the site gets used. Nothing loads until you accept. Privacy policy