Et
EditText.app

Regex Tester — Test Regular Expressions Online

Test and debug regular expressions online. Free regex tester with live match highlighting, capture groups, flags, and match list. No signup needed.

🔒 Your text stays in your browser — nothing is sent to our servers
//g
Flags:Global
How to Use

Three steps to get started

1

Enter a regex pattern

Type your regular expression in the pattern field. The /pattern/flags notation is shown — enter only the pattern itself, then toggle flags below.

2

Paste your test string

Enter the text you want to test against in the test string area. Matches are highlighted in real time as you type.

3

Review matches and replace

Check the match count, highlighted positions, and captured groups. Expand the Replace section to test a substitution.

About This Tool

Regular expressions: essential and often mysterious

Regular expressions (regex) are a pattern-matching language supported by virtually every programming language, text editor, and command-line tool. Mastering regex unlocks powerful abilities: searching, validating, extracting, and transforming text in ways that would require dozens of lines of procedural code.

A regex tester is invaluable because regex syntax is dense and easy to get wrong. Small mistakes — a misplaced quantifier, a missing anchor, forgetting to escape a special character — can cause a pattern to match everything or nothing. Live testing with highlighted matches makes debugging immediate and visual.

Quick regex cheat sheet

  • [A-Za-z0-9] — alphanumeric character
  • ^\d+$ — entire string is digits only
  • \b\w+\b — whole words
  • (?i) — case insensitive (use the i flag instead in this tester)
  • https?://\S+ — match URLs
  • (\d{1,3}\.){3}\d{1,3} — IPv4 address
  • ^.{0,160}$ — strings up to 160 characters

All regex matching runs in your browser using the JavaScript RegExp engine. No patterns or test strings are sent to any server.

FAQ

Frequently Asked Questions

Related Tools