tools/text/regex tester
// text

regex tester

live match highlighting, explain mode

/ /g
— enter a pattern // client-only
// matches appear here
// matches
— enter a pattern above
// reference
characters
digit 0–9
non-digit
word char
non-word
whitespace
non-whitespace
any (not \n)
newline
tab
anchors
line start
line end
word boundary
non-boundary
quantifiers
0+ greedy
1+ greedy
0 or 1
exactly n
n to m
0+ lazy
1+ lazy
groups & sets
capture
non-capture
lookahead
neg lookahead
char set
negated set
or
curl -sX POST 'https://api.whittly.dev/v1/regex/test' \
  -H 'Authorization: Bearer $WHITTLY_API_KEY' \
  -H 'Content-Type: application/json' \
  -d '{"pattern":"\\d+","flags":"g","input":"order 42"}'
const res = await fetch('https://api.whittly.dev/v1/regex/test', {
  method: 'POST',
  headers: {
    'Authorization': 'Bearer ' + apiKey,
    'Content-Type': 'application/json',
  },
  body: JSON.stringify({ pattern: "\\d+", flags: "g", input: "order 42" }),
});
const data = await res.json();
const { data } = await axios.post(
  'https://api.whittly.dev/v1/regex/test',
  { pattern: "\\d+", flags: "g", input: "order 42" },
  { headers: { Authorization: 'Bearer ' + apiKey } }
);
// prosaved patternspro·history syncproupgrade →
// history
Pro Cloud Sync — upgrade
no operations yet