Please enable JavaScript to use regex101
Regular
Expressions
101
Support Regex101
Social
Info
Regex Editor
Community Patterns
Account
Regex Quiz
Order By
Most Recent
Most upvotes
Most downvotes
Highest Score
Lowest Score
Relevance
Filter by Flavor
PCRE2 (PHP)
ECMAScript (JavaScript)
Python
Golang
Java
.NET 7.0 (C#)
Rust
PCRE (Legacy)
Sponsors
There are currently no sponsors.
Become a sponsor today!
Community Patterns
Search among community submitted regex patterns...
0/512
0
HTML5 email regex
Created
·
2023-07-09 03:48
Flavor
·
PCRE2 (PHP)
Source Mozilla.
Submitted by
anonymous
0
IP address validation
Created
·
2023-06-14 05:09
Flavor
·
PCRE2 (PHP)
IP address validation
Submitted by
anonymous
0
URL Validation
Created
·
2023-06-09 06:36
Flavor
·
.NET 7.0 (C#)
Can be used to validate on URL's.
Submitted by
anonymous
0
EmailValidation
Created
·
2023-06-07 05:52
Flavor
·
PCRE2 (PHP)
This is an Email validation using RegExp.
Submitted by
anonymous
0
Official Emeil validation Regex
Created
·
2023-06-01 13:35
Flavor
·
ECMAScript (JavaScript)
Regex from the Mail::RFC822::Address: regexp-based address validation Access here
Submitted by
Igor Julliano Aguiar Sotero
0
NIgerian Phone Numbers RegEx Validation
Created
·
2023-05-02 15:57
Flavor
·
PCRE2 (PHP)
This RegEx validates whether a number is in the standard valid Nigerian mobile number format or not.
Submitted by
funmitoblessed
0
Git Commit Message Validation
Created
·
2023-03-17 09:33
Flavor
·
Python
Validate a modified Version of https://udacity.github.io/git-styleguide/
Submitted by
anonymous
0
tas-branch-validation
Created
·
2023-03-16 10:07
Flavor
·
Java
tas-branch-validation
Submitted by
doron-hafner
0
Yii regex email validation
Created
·
2023-03-01 14:30
Flavor
·
PCRE2 (PHP)
Extract this regex from EmailValidation.php
Submitted by
Qiang Xue
0
Email Validation
Created
·
2023-02-28 21:46
Flavor
·
PCRE2 (PHP)
Validates email
Submitted by
anonymous
0
Javascript HTTP URL Validation
Created
·
2023-02-22 22:14
Flavor
·
PCRE2 (PHP)
Use to validate basic website URLs with or without http://. I took bits and pieces of other regexes I found and compiled into one that worked well for my purposes.
Submitted by
Daniel Ecker
0
Strict URL Validation - 2
Created
·
2023-02-18 07:20
Flavor
·
PCRE2 (PHP)
https://regex101.com/ https://www.cloudways.com/blog/prevent-laravel-xss-exploits/ https://cloudways.com
Submitted by
Adwin
0
IPv4 address validation
Created
·
2023-02-17 10:07
Flavor
·
PCRE2 (PHP)
validation of IPv4 addresses
Submitted by
@unblog
0
IPv6 address validation
Created
·
2023-02-17 10:08
Flavor
·
PCRE2 (PHP)
address validation from the first two segments of an IPv6 address
Submitted by
@unblog
0
Strict URL validation
Created
·
2023-02-10 11:57
Flavor
·
PCRE2 (PHP)
(?!..]{2})((https?|http)\:\/\/)?([a-z0-9+!(),;?&=\$.-]+(\:[a-z0-9+!(),;?&=\$.-]+)?@)?([a-z0-9-.-.]?(?!.\/).)\.([a-z]{2,1000})(\:[0-9]{2,5})?(\/([a-z0-9+\$-]\.?)+)\/?(\?[a-z+&\$.-)?(#a-z_.-)?
Submitted by
Adwin Raj GP
0
Email
Created
·
2023-02-08 08:40
Flavor
·
PCRE2 (PHP)
This is used for simple email validation
Submitted by
Pritesh
0
links
Created
·
2023-02-06 19:58
Flavor
·
PCRE2 (PHP)
links validation
Submitted by
ahmedfawzi
0
CSS RGB validation
Created
·
2023-02-06 02:30
Updated
·
2023-02-06 03:11
Flavor
·
ECMAScript (JavaScript)
It validates the RGB expression doesn't break the CSS parser.
Submitted by
Martin
0
Custom HTML/JavaScript email input validation
Created
·
2023-01-25 20:09
Updated
·
2023-01-25 21:15
Flavor
·
ECMAScript (JavaScript)
Only meant as an initial client-side filter to override the default input[type=email] validation done according to spec, which is much too simple. Inputs passing this regex MUST get validated in a more fine-grained manner again when received on the server-side
Submitted by
Neel Yadav
0
AAU CPR validation (more rebust)
Created
·
2023-01-25 11:33
Flavor
·
PCRE2 (PHP)
This one makes sure to not match 31 in months where it does not exist and cuts off february at 28. Might need to do special check for 29th of february ..?
Submitted by
anonymous
0
DK CPR Validation
Created
·
2023-01-25 09:41
Flavor
·
PCRE2 (PHP)
Checks in input for matching social security numbers in Denmark
Submitted by
Found online
0
Mail address validation
Created
·
2023-01-16 13:06
Flavor
·
ECMAScript (JavaScript)
Validates mail addresses
Submitted by
Sjoerd de Vries
0
Password validation
Created
·
2023-01-16 13:01
Flavor
·
ECMAScript (JavaScript)
Regex used for password validation. A password match the following: At least 8 characters in length Minimum of 1 lower-case character Minimum of 1 upper-case character Minimum of 1 digit Minimum of 1 special character (non-whitespace)
Submitted by
Sjoerd de Vries
0
Find validation name and name inside parentheses
Created
·
2022-12-23 03:40
Flavor
·
ECMAScript (JavaScript)
Find validation name and name inside parentheses
Submitted by
nghilq
0
email valid
Created
·
2022-12-12 02:29
Flavor
·
Java
email validation
Submitted by
Hoot
0
VLAN ID Validation Regex
Created
·
2022-12-09 13:32
Flavor
·
Golang
VLAN ID Validation Regex Please use first segment or second depending on the Extended VLAN usage such as "1-256" or "1-4096" : Non-extended VLAN IDs (1-256), check v2 of the regex entry ^(25[0-6]|(2[0-4]|1\d|[1-9])\d|[1-9])$ Extended VLAN IDs (1-4096), check v3 of the regex entry ^(409[0-6]|(40[0-8]|[1-3]\d\d|[1-9]\d|[1-9])\d|[1-9])$
Submitted by
ulgena
0
IPv4 Address Validation Regex
Created
·
2022-12-09 13:08
Updated
·
2022-12-09 13:09
Flavor
·
Golang
IPv4 Address Validation Regex
Submitted by
ulgena
0
Validate Date Represented by Integer 1900 - 2099
Created
·
2022-11-19 16:22
Flavor
·
PCRE (Legacy)
Very simple validation expression that will validate a date in the range of 19000101 through 20991231. These formats are very popular for partitioning and representing dates as Long values or Integers. This does not check for Leap year values, or the months with varying number of days. Please Note: this will return a match on 20220231 even though this is not a valid date. Additional validations should be used if Leap years and Days of the Month should be verified as well.
Submitted by
Edward Rush
0
Date validation in yyyy-mm-dd format
Created
·
2022-10-29 19:03
Flavor
·
ECMAScript (JavaScript)
Comes with choice of four separators
Submitted by
Regular-Expressions.info
0
Validation code FETLOCK pt-br
Created
·
2022-10-21 16:47
Updated
·
2023-10-24 02:28
Flavor
·
ECMAScript (JavaScript)
Validação de código de barras boleto padrão "FEBRABAN - Federação Brasileira de Bancos".
Submitted by
Rafaella Cintra
0
Safe EMail validation (protected against ReDos) v2
Created
·
2022-10-08 06:42
Flavor
·
ECMAScript (JavaScript)
Safe EMail validation protected against ReDos attack. Exclude all non conventionnal special char like #{%... only accept . - and _. . EMail can't start with number or specials chars. Domain accept only one subdomain and ip are available 63 Maximum characters accepted Check for valid IP
Submitted by
J.Delauney
0
Safe EMail Validation (protected against ReDos)
Created
·
2022-10-07 21:54
Flavor
·
ECMAScript (JavaScript)
Safe EMail validation protected against ReDos attack. It exclude all non conventionnal special char like #{%... only accept . - and _. . EMail can't start with number or specials chars. Domain accept only one subdomain and ip are available 63 Maximum characters accepted
Submitted by
J.Delauney
0
Russian phone validation
Created
·
2022-09-23 09:29
Updated
·
2023-10-02 21:09
Flavor
·
PCRE2 (PHP)
This expression validates russian phones in different formats
Submitted by
zkelo
0
basic email validation
Created
·
2022-08-16 15:34
Flavor
·
PCRE2 (PHP)
Basic email regex for quick validation
Submitted by
bUxEE
0
IPv4 w/ w/o port validation and localhost string supported
Created
·
2022-08-15 08:08
Flavor
·
PCRE (Legacy)
IPv4 w/ w/o port validation and localhost string supported
Submitted by
anonymous
0
Validation
Created
·
2022-08-14 08:07
Flavor
·
PCRE2 (PHP)
^a-zA-Z+@[a-zA-Z]{3,20}\.[a-z]{3}$
Submitted by
anonymous
0
Email input validation
Created
·
2022-08-14 00:56
Updated
·
2022-08-14 01:36
Flavor
·
ECMAScript (JavaScript)
Regex to validate an email input with the following rules... Whole address: Up to 254 characters. Case insensitive. Username and domain separated by @ symbol. Only one @ symbol allowed. No spaces allowed. Username: 1 to 64 characters. Any letter, digit and symbol from these #!%$'&+*-/=?^_.{|}~ are allowed. It cannot start or end with a dot. It cannot have two (or more) consecutive dots. Domain: Only letters, digits and hyphens (and dots of course) allowed. It cannot start or end with a dot. Unlimited number of labels separated by one dot allowed. No label can start nor end with hyphens. It cannot have two (or more) consecutive dots. 2 to 63 characters per label. It cannot have an all-numerical TLD.
Submitted by
chCharly
0
Date dd.mm.yyyy
Created
·
2022-08-10 08:46
Flavor
·
PCRE2 (PHP)
Regex for datestring validation
Submitted by
anonymous
0
UK PostCode Validation
Created
·
2022-08-06 16:29
Flavor
·
.NET 7.0 (C#)
Flexible postcode validation with or without space as outlined here, but added optional space for flexibility https://assets.publishing.service.gov.uk/government/uploads/system/uploads/attachment_data/file/488478/Bulk_Data_Transfer_-_additional_validation_valid_from_12_November_2015.pdf
Submitted by
anonymous
0
Multiple MAC Address Validation
Created
·
2022-07-28 23:50
Flavor
·
PCRE2 (PHP)
Used to validate the list of MAC addresses is formatted correctly. The list of MACs can use ":", "-", or "." as a separator: Example with a "-" separator: 00-11-22-33-44-55 Example with a ":" separator: 00:11:22:33:44:55 Example with a "." separator: 0011.2233.4455
Submitted by
Joel Jordan
0
Email validation regex
Created
·
2022-07-23 17:46
Updated
·
2022-07-23 18:49
Flavor
·
Python
This email validation regex works perfectly (99.99%) for validating email address entries. The regex does not match email addresses with with the following characteristics: Addresses that begin/end with a special character Addresses with consecutive repeated special characters Special characters matched are: Period (".") Hyphen ("-") Underscore ("_") https://regex101.com/r/0NVXwu/1
Submitted by
Bright Owusu
0
Bandwidth value validation
Created
·
2022-07-22 17:30
Flavor
·
Python
Bandwidth value validation: 1-1023K 1-1023M 1-40G
Submitted by
Damien Stuart
0
Ipv4 validation
Created
·
2022-06-28 11:08
Flavor
·
PCRE2 (PHP)
regex for ip validation
Submitted by
Amper
0
Phone # Validation
Created
·
2022-06-16 17:42
Flavor
·
ECMAScript (JavaScript)
This recognizes phone numbers, including country codes if they're present.
Submitted by
Phoenix Staley
0
URL Validation JS
Created
·
2022-06-29 09:42
Updated
·
2022-10-12 09:17
Flavor
·
ECMAScript (JavaScript)
Domain can be an IP address, except 0.0.0.0 Domain with length of 1 accepted Only acceptable symbol in Domain is "-" (hyphen) Not allowed in start, end or twice in a row (same for "." (dot))
Submitted by
Artur
0
mac address validation
Created
·
2022-06-07 08:10
Flavor
·
PCRE2 (PHP)
mac address validation in hex or decimal form
Submitted by
planetwatch.io
0
6 Digit Numeric Length
Created
·
2022-06-02 06:02
Updated
·
2022-06-03 00:48
Flavor
·
ECMAScript (JavaScript)
This Test will check is the given string is Exactly of 6 digits & all chars are Numbers. use case OTP Validations.
Submitted by
anonymous
0
Name regex
Created
·
2022-04-22 11:07
Flavor
·
PCRE2 (PHP)
Custom name validation
Submitted by
anonymous
0
Email simple validation (x@x.x)
Created
·
2022-04-18 00:27
Updated
·
2022-11-04 18:14
Flavor
·
PCRE2 (PHP)
Simple email validator (x@x.x) Note: Use /g to test all example emails.
Submitted by
davidgaroro
0
web validation
Created
·
2022-04-05 10:25
Flavor
·
PCRE2 (PHP)
web validation
Submitted by
anonymous
Load More
Community Library Entry
0
Regular Expression
Created
·
2023-03-01 14:30
Flavor
·
PCRE2 (PHP)
/
^
[
a
-
zA
-
Z0
-
9!#$%&
\'
*+
\\\=
?^_`{|}~-
]
+
(?:
\.
[
a
-
zA
-
Z0
-
9!#$%&
\'
*+
\\\=
?^_`{|}~-
]
+
)*
@
(?:
[
a
-
zA
-
Z0
-
9
]
(?:
[
a
-
zA
-
Z0
-
9-
]
*
[
a
-
zA
-
Z0
-
9
]
)?
\.
)+
[
a
-
zA
-
Z0
-
9
]
(?:
[
a
-
zA
-
Z0
-
9-
]
*
[
a
-
zA
-
Z0
-
9
]
)?
$
/
Open regex in editor
Description
Extract this regex from
EmailValidation.php
Submitted by
Qiang Xue