Regular Expression
//g
Flags:
Test String
Matches Highlighted1 match found
The quick brown fox jumps over the lazy dog. Email: test@example.com, Phone: 123-456-7890

All Matches

test@example.com

About Regex Tester & Playground

1What is it?

Test your Regular Expressions (Regex) in real-time. This interactive playground highlights matches as you type, helping you debut and refine complex patterns. Supports standard JavaScript Regex features including flags, capture groups, and lookaheads.

2Use Cases

  • Validate email or phone number patterns
  • Debug why a specific regex isn't matching
  • Extract data using capture groups
  • Learn regex syntax by experimenting
  • Verify password strength rules

3Examples

Email Validation

Input

user@example.com

Output

Matches: matches email pattern

Date Extraction

Input

2024-01-01

Output

Capture Groups: Year, Month, Day

?Frequently Asked Questions

Which Regex flavor is supported?

We use the JavaScript RegExp engine, which is standard for web development and supports most common regex features like greedy/lazy quantifiers and positive/negative lookaheads.

How do I match newlines?

Use the 'Global' (g) and 'Multiline' (m) flags. The dot (.) typically doesn't match newlines, so use [\s\S] to match absolutely any character including line breaks.