News

🔍 Regex Tester

Test regex patterns with live match highlighting.

Pattern
/ /
EmailIPv4URLUUIDDate YYYY-MM-DDSemver
Test String
Matches (2)
hello@example.com test@domain.org not-an-email
[0] hello@example.com group1: hellogroup2: example
[1] test@domain.org group1: testgroup2: domain
Replace / Substitution
👑
Pro Feature
Regex substitution & replace is available on the Pro plan.

About the Regex Tester

A regular expression (regex or regexp) is a sequence of characters that defines a search pattern. Regular expressions are supported by virtually every programming language and text processing tool, and are used to match, search, validate, extract, and transform strings.

Regex building blocks

  • Literal characters — match themselves exactly: cat matches the string "cat".
  • Character classes[abc] matches any one of a, b, or c. \w matches any word character (letters, digits, underscore). \d matches any digit. \s matches any whitespace.
  • Quantifiers* (zero or more), + (one or more), ? (zero or one), {n,m} (between n and m times).
  • Anchors^ matches the start of a line; $ matches the end.
  • Groups(...) captures a subexpression for extraction; (?:...) groups without capturing.
  • Alternationa|b matches either a or b.

Flags

  • gglobal: find all matches, not just the first.
  • icase-insensitive: A matches both uppercase and lowercase a.
  • mmultiline: ^ and $ match line boundaries instead of the start and end of the whole string.

How to use this tool

Enter your regex pattern in the Pattern field and your test text in the Test String area. Matches are highlighted live. All matched groups are listed below the output so you can verify capture group contents without running the code. Use the preset chips to quickly load common patterns for email addresses, IPv4 addresses, URLs, UUIDs, dates, and semantic version numbers.