Free Online Regex Tester & Debugger
Test and debug regular expressions online with real-time matching, replace preview, and common pattern templates. Supports all regex flags. Free regex testing tool for developers.
//g
Email
URL
Phone (US)
IP Address
Date (YYYY-MM-DD)
Hex Color
Credit Card
Username
Enter text to see matches
Find & Replace
Use $1, $2, etc. to reference capture groups
Enter replacement text to see result
Related Developer Tools
Base64 Encode/DecodeTimestamp ConverterQR Code GeneratorLorem Ipsum GeneratorURL Encode/DecodeHash GeneratorCase ConverterWord CounterText DiffColor PickerUUID GeneratorRegex TesterJWT DecoderMarkdown PreviewHTML to MarkdownMarkdown to HTMLYAML to JSONCron ParserHTML BeautifierCSS BeautifierJavaScript BeautifierPassword GeneratorSQL FormatterJSON to TypeScriptSlug GeneratorNumber Base ConverterChmod CalculatorEscape/UnescapeJSON Path FinderIP Address ToolsText to BinaryHTML Entity EncoderUnicode CheckerCSV ViewerXML BeautifierYAML ValidatorRemove DuplicatesBase32 Encode/DecodeString LengthText ReverseHex EditorTOML ParserCSV to XMLXML to CSVMD Table GeneratorCountdown TimerRandom NumberRandom PickerUnit ConverterASCII ArtEmoji PickerJSON to GoOG PreviewHTTP Status CodesRegex LibraryCSS GradientBox ShadowFavicon GeneratorHMAC GeneratorRSA Key GeneratorJSON to RustJSON to JavaJSON to PythonAES Encrypt/DecryptSHA-3 HashTOTP GeneratorPassword CheckerCertificate ParserExcel to JSONSQL to CSVYAML FormatterText to SpeechDiff to PatchSVG EditorCrontab GeneratorGit CommandsDocker Compose
What is Regex Tester?
Regex Tester is a tool for testing and debugging regular expressions (regex). Regular expressions are patterns used to match character combinations in strings. They're essential for text processing, validation, search, and data extraction in programming.
How to Use Regex Tester
- Enter your regular expression pattern
- Select appropriate flags (global, case-insensitive, etc.)
- Type or paste test text to match against
- View highlighted matches and use replace preview if needed
Regex Tester Features
- Real-time pattern matching with highlighting
- Support for all regex flags (g, i, m, s, u)
- Common regex templates (email, URL, phone, etc.)
- Find and replace with group references
- Detailed match information with capture groups
Regex Tester FAQ
- What do the flags mean?
- g (global) finds all matches; i (ignore case) makes matching case-insensitive; m (multiline) makes ^ and $ match line boundaries; s (dotAll) makes . match newlines; u (unicode) enables full Unicode support.
- How do capture groups work?
- Parentheses () create capture groups. In the replacement, use $1 for the first group, $2 for the second, etc. Groups let you extract and reuse parts of matched text.
- Why isn't my regex matching?
- Common issues: forgetting to escape special characters (. * + ? etc.), not enabling the global flag for multiple matches, or case sensitivity. Try the 'i' flag for case-insensitive matching.