Regular Expression Testing
Online test and validate regular expressions, supports real-time matching, replacement function, and common regular expression examples.
Matching Results
Found 0 matches
Common Regular Expression Reference
Email Address
^\w+@[a-zA-Z_]+?\.[a-zA-Z]{2,3}$
Phone Number
^1[3-9]\d{9}$
URL
^(https?:\/\/)?([\da-z\.-]+)\.([a-z\.]{2,6})([\/\w \.-]*)*\/?$
IPv4 Address
^(?:(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.){3}(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)$
ID Number
^[1-9]\d{5}(?:19|20)\d{2}(?:0[1-9]|1[0-2])(?:0[1-9]|[12]\d|3[01])\d{3}[\dXx]$
Password Strength
^(?=.*[A-Za-z])(?=.*\d)[A-Za-z\d]{8,}$
Regular Expression Syntax Reference
Character Classes
.
Match any character (except newline)
\d
Match numbers [0-9]
\w
Match letters, numbers, and underscores [A-Za-z0-9_]
\s
Match whitespace characters (space, tab, newline)
Quantifiers
*
Match 0 or more times
+
Match 1 or more times
?
Match 0 or 1 time
{n}
Match exactly n times
Boundaries
^
Match start of line
$
Match end of line
\b
Match word boundary