s2e-lab/RegexEval huggingface dataset:
Matches exactly 1 numeric digit (0-9).
Match examples:
- "1"
- "2"
- "3"
Non-match examples:
- "a"
- "324"
Regular expression: ^\d$
Matches 5 numeric digits, such as a zip code.
Match examples:
- "33333"
- "55555"
- "23445"
Non-match examples:
- "abcd"
- "1324"
Regular expression: ^\d{5}$
Matches a string that starts with five digits, followed by a hyphen, and ends with four digits.
Match examples:
- "22222-3333"
- "34545-2367"
- "56334-2343"
Non-match examples:
- "123456789"
- "A3B 4C5"
Regular expression: ^\d{5}-\d{4}$
Match either a 5 digit ZIP code or a ZIP+4 code formatted as a string that starts with five digits, followed by a hyphen, and ends with four digits..
Match examples:
- "55555-5555"
- "34564-3342"
- "90210"
Non-match examples:
- "434454444"
- "645-32-2345"
Regular expression: ^\d{5}$|^\d{5}-\d{4}$
This regular expression will match a hyphen-separated Social Security Number (SSN) in the format NNN-NN-NNNN.
Match examples:
- "333-22-4444"
- "123-45-6789"
- "534-74-2573"
Non-match examples:
- "123456789"
- "SSN"
Regular expression: ^\d{3}-\d{2}-\d{4}$
Matches any single upper- or lower-case letter.
Match examples:
- "a"
- "B"
- "c"
Non-match examples:
- "0"
- "&amp;"
Regular expression: ^[a-zA-Z]$
Matches any string of only upper- and lower- case letters (no spaces).
Match examples:
- "abc"
- "ABC"
- "aBcDeF"
Non-match examples:
- "abc123"
- "mr."
Regular expression: ^[a-zA-Z]+$
Matches any alphanumeric string (a string that contains only English letters and/or digits without spaces).
Match examples:
- "10a"
- "ABC"
- "A3fg"
Non-match examples:
- "45.3"
- "this or that"
Regular expression: ^[a-zA-Z0-9]+$
Positive integer value.
Match examples:
- "123"
- "10"
- "54"
Non-match examples:
- "-54"
- "54.234"
Regular expression: ^\d+$
Matches any signed integer, in other words, a string that can start with an optional plus (+) or minus (-) sign, followed by one or more digits.
Match examples:
- "-34"
- "34"
- "+5"
Non-match examples:
- "abc"
- "3.1415"
Regular expression: ^(\+|-)?\d+$
The password's first character must be a letter, it must contain at least 4 characters and no more than 15 characters and no characters other than letters, numbers and the underscore may be used.
Match examples:
- "abcd"
- "aBc45DSD_sdf"
- "password"
Non-match examples:
- "afv"
- "1234"
Regular expression: ^[a-zA-Z]\w{3,14}$
Checks if an email address starts with one or more alphanumeric characters, followed by the "@" symbol, a domain name with letters or underscores, a dot, and finally a domain extension with two or three letters.
Match examples:
- "joe@aol.com"
- "ssmith@aspalliance.com"
- "a@b.cc"
Non-match examples:
- "joe@123aspx.com"
- "joe@web.info"
Regular expression: ^\w+@[a-zA-Z_]+?\.[a-zA-Z]{2,3}$
This regular expressions matches dates of the form XX/XX/YYYY where XX can be 1 or 2 digits long and YYYY is always 4 digits long.
Match examples:
- "4/1/2001"
- "12/12/2001"
- "55/5/3434"
Non-match examples:
- "1/1/01"
- "12 Jan 01"
Regular expression: ^\d{1,2}\/\d{1,2}\/\d{4}$
Matches a single digit between 1 and 5, inclusive. It will only match a single character that is exactly one of the digits 1, 2, 3, 4, or 5, and is the same as saying ^[12345]$.
Match examples:
- "1"
- "3"
- "4"
Non-match examples:
- "6"
- "23"
Regular expression: ^[1-5]$
This matches a single numeric digit between 1 and 5, and is the same as saying ^[1-5]$.
Match examples:
- "1"
- "2"
- "4"
Non-match examples:
- "6"
- "-1"
Regular expression: ^[12345]$
This expression matches a hyphen separated US phone number, of the form ANN-NNN-NNNN, where A is between 2 and 9 and N is between 0 and 9.
Match examples:
- "800-555-5555"
- "333-444-5555"
- "212-666-1234"
Non-match examples:
- "000-000-0000"
- "123-456-7890"
Regular expression: ^[2-9]\d{2}-\d{3}-\d{4}$
Match strings that start with one or more alphanumeric characters, hyphens, or dots, followed by a dot, and end with either "com", "org", "net", "mil", or "edu" (case insensitive). This is typically used to validate domain names.
Match examples:
- "3SquareBand.com"
- "asp.net"
- "army.mil"
Non-match examples:
- "$SquareBand.com"
- "asp/dot.net"
Regular expression: ^[a-zA-Z0-9\-\.]+\.(com|org|net|mil|edu|COM|ORG|NET|MIL|EDU)$
Password expression. Password must be between 4 and 8 digits long and include at least one numeric digit.
Match examples:
- "1234"
- "asdf1234"
- "asp123"
Non-match examples:
- "asdf"
- "asdf12345"
Regular expression: ^(?=.*\d).{4,8}$
Password matching expression. Password must be at least 4 characters, no more than 8 characters, and must include at least one upper case letter, one lower case letter, and one numeric digit.
Match examples:
- "asD1"
- "asDF1234"
- "ASPgo123"
Non-match examples:
- "asdf"
- "1234"
Regular expression: ^(?=.*\d)(?=.*[a-z])(?=.*[A-Z]).{4,8}$
Ensures that the string matches a valid IP address format, where each part of the address falls within the range of 0 to 255.
Match examples:
- "127.0.0.1"
- "255.255.255.0"
- "192.168.0.1"
Non-match examples:
- "1200.5.4.3"
- "abc.def.ghi.jkl"
Regular expression: ^(25[0-5]|2[0-4][0-9]|[0-1]{1}[0-9]{2}|[1-9]{1}[0-9]{1}|[1-9])\.(25[0-5]|2[0-4][0-9]|[0-1]{1}[0-9]{2}|[1-9]{1}[0-9]{1}|[1-9]|0)\.(25[0-5]|2[0-4][0-9]|[0-1]{1}[0-9]{2}|[1-9]{1}[0-9]{1}|[1-9]|0)\.(25[0-5]|2[0-4][0-9]|[0-1]{1}[0-9]{2}|[1-9]{1}[0-9]{1}|[0-9])$
Starts with one or more word characters, dots, equal signs, or hyphens.
Followed by an @ symbol.
Followed by one or more word characters, dots, hyphens, or dots.
Followed by a dot (.)
Ends with two or three word characters.
Match examples:
- "a@a.com"
- "a@a.com.au"
- "a@a.au"
Non-match examples:
- "word"
- "word@"
Regular expression: ^[\w\.=-]+@[\w\.-]+\.[\w]{2,3}$
Matches strings that start with a dollar sign, followed by one or more digits, and optionally followed by a dot and exactly two more digits representing the decimal part.
Match examples:
- "$1.50"
- "$49"
- "$0.50"
Non-match examples:
- "1.5"
- "$1.333"
Regular expression: ^\$[0-9]+(\.[0-9][0-9])?$
This pattern allows standard e-mail addresses (e.g. user@domain.com), sub domains (e.g. user@foo.domain.com), the new two- and four-letter domains (e.g. user@domain.tv and user@domain.name) and country codes (e.g. user@foo.com.us). Also, this patter follows the Network Solutions standard length of 67 characters for top-level domains.
Match examples:
- "foo@foo.com"
- "foo@foo-foo.com.au"
- "foo@foo.foo.info"
Non-match examples:
- "foo@.com"
- "foo@foo..com"
Regular expression: ^([\w\d\-\.]+)@{1}(([\w\d\-]{1,67})|([\w\d\-]+\.[\w\d\-]{1,67}))\.(([a-zA-Z\d]{2,4})(\.[a-zA-Z\d]{2})?)$
Matches strings that consist entirely of one or more digits (0-9).
Match examples:
- "1234567890"
- "4123109"
- "53421"
Non-match examples:
- "f423"
- "f34fvfv"
Regular expression: ^[0-9]+$
Matches any string between 4 and 8 characters in length. Limits the length of a string.
Match examples:
- "asdf"
- "1234"
- "asdf1234"
Non-match examples:
- "asd"
- "123"
Regular expression: ^.{4,8}$
Accepts an unsigned integer number. Also matches empty strings.
Match examples:
- "123"
- "000"
- "43"
Non-match examples:
- "asbc"
- "-34"
Regular expression: ^\d*$
Matches any integer number or numeric string, including positive and negative value characters (+ or -). Also matches empty strings.
Match examples:
- "123"
- "-123"
- "+123"
Non-match examples:
- "abc"
- "3.14159"
Regular expression: ^[-+]?\d*$
Matches any unsigned floating point number/numeric string. Also matches empty strings.
Match examples:
- "123"
- "3.14159"
- ".234"
Non-match examples:
- "abc"
- "-3.14159"
Regular expression: ^\d*\.?\d*$
Matches US phone number format. 1 in the beginning is optional, area code is required, spaces or dashes can be used as optional divider between number groups. Also alphanumeric format is allowed after area code.
Match examples:
- "1-(123)-123-1234"
- "123 123 1234"
- "1-800-ALPHNUM"
Non-match examples:
- "1.123.123.1234"
- "(123)-1234-123"
Regular expression: ^([0-9]( |-)?)?(\(?[0-9]{3}\)?|[0-9]{3})( |-)?([0-9]{3}( |-)?[0-9]{4}|[a-zA-Z0-9]{7})$
Matches a string if it is a valid time in the format of HH:MM
Match examples:
- "02:04"
- "16:56"
- "23:59"
Non-match examples:
- "02:00 PM"
- "PM2:00"
Regular expression: ^([0-1][0-9]|[2][0-3]):([0-5][0-9])$
Match strings that consist of alphabetic characters (both lowercase and uppercase) and commas, allowing for leading and trailing whitespace.
Match examples:
- "Smith, Ed"
- "Ed Smith"
- "aBcDeFgH"
Non-match examples:
- "a123"
- "AB5"
Regular expression: ^\s*[a-zA-Z,\s]+\s*$
Matches standard 5 digit US Zip Codes, or the US ZIP + 4 Standard.
Match examples:
- "48222"
- "48222-1746"
- "51314"
Non-match examples:
- "4632"
- "Blake"
Regular expression: ^\d{5}(-\d{4})?$
Match strings representing Dutch-style phone numbers. It allows for an optional country code, with various formats accepted. Possible example prefixes: +31, +31(0), (+31)(0), 0, 0031
followed by 9 numbers (which can contain a space or -). The main content of the phone number can consist of nine or ten digits, with optional hyphens or spaces in the ten-digit format.
Match examples:
- "+31235256677"
- "+31(0)235256677"
- "023-5256677"
Non-match examples:
- "+3123525667788999"
- "3123525667788"
Regular expression: (^\+[0-9]{2}|^\+[0-9]{2}\(0\)|^\(\+[0-9]{2}\)\(0\)|^00[0-9]{2}|^0)([0-9]{9}$|[0-9\-\s]{10}$)
Checks for a 10 digit number where the last digit could also be a capital 'X'.
Match examples:
- "1234123412"
- "123412341X"
- "4738195735"
Non-match examples:
- "not an isbn"
- "54390853"
Regular expression: ^\d{9}[\d|X]$
The regular expression represents a date format where the day, month, and year are separated by forward slashes (/), and the allowed ranges for each component are:
day (d or dd): from 1 to 31
month (m or mm): from 1 to 12
year (yy or yyyy): from 1900 to 2099
Match examples:
- "01/01/2001"
- "1/1/1999"
- "10/20/2080"
Non-match examples:
- "13/01/2001"
- "1/1/1800"
Regular expression: ^(([1-9])|(0[1-9])|(1[0-2]))\/(([0-9])|([0-2][0-9])|(3[0-1]))\/(([0-9][0-9])|([1-2][0,9][0-9][0-9]))$
This is a pattern to search and verify that a decimal number ends with a 25, 50, 75, 0 or 00. It also match for nothing after decimal or even without decimal point.
Match examples:
- "0.25"
- ".75"
- "123.50"
Non-match examples:
- ".77"
- "1.435"
Regular expression: ^\d*\.?((25)|(50)|(5)|(75)|(0)|(00))?$
This regular expression matches two patterns:

1. A valid U.S. ZIP code, which can be either in the format "12345-6789" or just "12345."
2. A valid Canadian postal code, which is in the format "A1A 1A1" (a letter, a digit, a letter, a space, a digit, a letter, a digit).
Match examples:
- "78754"
- "78754-1234"
- "G3H 6A3"
Non-match examples:
- "78754-12aA"
- "7875A"
Regular expression: ^(\d{5}-\d{4}|\d{5})$|^([a-zA-Z]\d[a-zA-Z] \d[a-zA-Z]\d)$
This regular expression is used to validate codes with a specific format(UK postcodes), where the code starts with 1 to 2 letters, followed by 1 to 2 alphanumeric characters, an optional space, 0 to 1 digit, and ends with exactly 2 letters.
Match examples:
- "SW112LE"
- "SW11 2LE"
- "CR05LE"
Non-match examples:
- "12CR0LE"
- "12CR 0LE"
Regular expression: ^[A-Za-z]{1,2}[0-9A-Za-z]{1,2}[ ]?[0-9]{0,1}[A-Za-z]{2}$
This regular expression is used to validate date-time strings in a specific ISO 8601 format, where the year is in the 21st century, and it includes the year, month, day, hour, minute, and second components, separated by either hyphens or slashes, with a "T" or a space between the date and time.
Match examples:
- "2099-12-31T23:59:59"
- "2002/02/09 16:30:00"
- "2000-01-01T00:00:00"
Non-match examples:
- "2000-13-31T00:00:00"
- "2002/02/33 24:00:00"
Regular expression: 20\d{2}(-|\/)((0[1-9])|(1[0-2]))(-|\/)((0[1-9])|([1-2][0-9])|(3[0-1]))(T|\s)(([0-1][0-9])|(2[0-3])):([0-5][0-9]):([0-5][0-9])
- validates a yyyy-mm-dd, yyyy mm dd, or yyyy/mm/dd date
- makes sure day is within valid range for the month
- does NOT validate Feb. 29 on a leap year, only that Feb. CAN have 29 days
Match examples:
- "0001-12-31"
- "9999 09 30"
- "2002/03/03"
Non-match examples:
- "0001\02\30"
- "9999.15.01"
Regular expression: ^\d{4}[\-\/\s]?((((0[13578])|(1[02]))[\-\/\s]?(([0-2][0-9])|(3[01])))|(((0[469])|(11))[\-\/\s]?(([0-2][0-9])|(30)))|(02[\-\/\s]?[0-2][0-9]))$
US Telephone Reg expression that allows 7, 10 or 11 digits with or without hyphens.
Match examples:
- "15615552323"
- "1-561-555-1212"
- "5613333"
Non-match examples:
- "1-555-5555"
- "15553333"
Regular expression: ^(1?(-?\d{3})-?)?(\d{3})(-?\d{4})$
This RegEx will help to validate a physical file path with a specific file extension (here xls)
Match examples:
- "E:\DyAGT\SD01A_specV2.xls"
- "E:\DyAGT\23FD.xls"
- "C:\DyAGT\VF2FV.xls"
Non-match examples:
- "E:\DyAGT\SD01A_specV2.txt"
- "E:\DyAGT\SD01A_specV2.jpg"
Regular expression: ([a-zA-Z]:(\\w+)*\\[a-zA-Z0_9]+)?.xls
Matches a 12-hour time value expressed as either 4 numeric digits, 3 numeric digits, or a space and 3 numeric digits. 3 digit times (930) can be expressed with leading 0's (0930) or not. AM/PM designation is not included in this expression.
Match examples:
- "1145"
- "933"
- "801"
Non-match examples:
- "0000"
- "1330"
Regular expression: ^( [1-9]|[1-9]|0[1-9]|10|11|12)[0-5]\d$
Accepts 1-2 digits followed by a slash followed by 2-4 digits.
Match examples:
- "9/02"
- "09/2002"
- "09/02"
Non-match examples:
- "Fall 2002"
- "Sept 2002"
Regular expression: ^\d{1,2}\/\d{2,4}$
This expression matches dates formatted as MM/DD/YYYY where months and days must be 2 digits each, zero padded. It allows DD to be from 01 to 31 regardless of the month.
Match examples:
- "01/01/2001"
- "02/30/2001"
- "12/31/2002"
Non-match examples:
- "1/1/02"
- "1/1/2002"
Regular expression: ^(|(0[1-9])|(1[0-2]))\/((0[1-9])|(1\d)|(2\d)|(3[0-1]))\/((\d{4}))$
Date expressions that matches MM/DD/YYYY where MM and DD must be two digits and zero padded. Validates correctly for all months except February, which it assumes to always have 29 days.
Match examples:
- "01/01/2001"
- "02/29/2002"
- "12/31/2002"
Non-match examples:
- "1/1/02"
- "02/30/2002"
Regular expression: ^((((0[13578])|(1[02]))[\/]?(([0-2][0-9])|(3[01])))|(((0[469])|(11))[\/]?(([0-2][0-9])|(30)))|(02[\/]?[0-2][0-9]))[\/]?\d{4}$
This regex match numeric data in the following format: thousands are separated by (') apostrophe, decimal places are separated by dot (.) Maximum three decimal places are not required.
Match examples:
- "1'235.140"
- "1'222'333.120"
- "456"
Non-match examples:
- "1234.500"
- "78'45.123"
Regular expression: ^(\d{1,3}'(\d{3}')*\d{3}(\.\d{1,3})?|\d{1,3}(\.\d{3})?)$
Fully functional date validator in format dd.MM.yyyy
Works only within range of years 2000-2099 !
It allows leading zeros but does not require them.
Match examples:
- "31.01.2002"
- "29.2.2004"
- "09.02.2005"
Non-match examples:
- "31.11.2002"
- "29.2.2002"
Regular expression: ^((0?[1-9]|[12][1-9]|3[01])\.(0?[13578]|1[02])\.20[0-9]{2}|(0?[1-9]|[12][1-9]|30)\.(0?[13456789]|1[012])\.20[0-9]{2}|(0?[1-9]|1[1-9]|2[0-8])\.(0?[123456789]|1[012])\.20[0-9]{2}|(0?[1-9]|[12][1-9])\.(0?[123456789]|1[012])\.20(00|04|08|12|16|20|24|28|32|36|40|44|48|52|56|60|64|68|72|76|80|84|88|92|96))$
This expression is an attempt to match the most obvious features of a valid date in American/US format of the form mm/dd/yyyy for any year 1900 through 2003. It matches any date where the day part is any number 01-31, the month part is any number 01-12, and the year part is any number 1900-2003. The only invalid dates that it matches are ones where the day part may be in the range 01-31 but that range might not be valid for the specified month. An example of an invalid date that it would allow to pass through would be 11/31/2002. This date is invalid because 11/31 of any year does not exist, but this expression would allow it pass through since the day part is in the range 01-31.
Match examples:
- "12/31/2003"
- "01/01/1900"
- "11/31/2002"
Non-match examples:
- "1/1/2002"
- "01/01/02"
Regular expression: ^(0[1-9]|1[0-2])\/((0[1-9]|2\d)|3[0-1])\/(19\d\d|200[0-3])$
The following validates dates with and without leading zeros in the following formats: MM/DD/YYYY and it also takes YYYY. All months are validated for the correct number of days for that particular month except for February which can be set to 29 days. date day month year
Match examples:
- "01/01/2001"
- "1/01/2001"
- "2002"
Non-match examples:
- "2/30/2002"
- "13/23/2002"
Regular expression: ^((((0[13578])|([13578])|(1[02]))[\/](([1-9])|([0-2][0-9])|(3[01])))|(((0[469])|([469])|(11))[\/](([1-9])|([0-2][0-9])|(30)))|((2|02)[\/](([1-9])|([0-2][0-9]))))[\/]\d{4}$|^\d{4}$
This matches any real number, with optional decimal point and numbers after the decimal, and optional positive (+) or negative (-) designation.
Match examples:
- "123"
- "-123.45"
- "+123.56"
Non-match examples:
- "123x"
- ".123"
Regular expression: ^[-+]?\d+(\.\d+)?$
This expression matches three different formats of postal codes: 5 digit US ZIP code, 5 digit US ZIP code + 4, and 6 digit alphanumeric Canadian Postal Code. The first one must be 5 numeric digits. The ZIP+4 must be 5 numeric digits, a hyphen, and then 4 numeric digits. The Canadian postal code must be of the form ANA NAN where A is any uppercase alphabetic character and N is a numeric digit from 0 to 9.
Match examples:
- "44240"
- "44240-5555"
- "T2P 3C7"
Non-match examples:
- "44240ddd"
- "t44240-55"
Regular expression: ^((\d{5}-\d{4})|(\d{5})|([A-Z]\d[A-Z]\s\d[A-Z]\d))$
Matches strings that consist of either exactly five digits or five digits followed by a hyphen and then exactly three more digits (optional). Can be used to match standard 5 digit Brazilian Postal Codes (CEP), or the CEP + 3 digits (distribution identifiers - suffix).
Match examples:
- "13165-000"
- "38175-000"
- "81470-276"
Non-match examples:
- "13165-00"
- "38175-abc"
Regular expression: ^\d{5}(-\d{3})?$
Matches US currency format with lead dollar sign. Dollar value must have at least one digit and may or may not be comma separated. Cents value is optional.
Match examples:
- "$0.84"
- "$123458"
- "$1,234,567.89"
Non-match examples:
- "$12,3456.01"
- "12345"
Regular expression: ^\$(\d{1,3}(\,\d{3})*|(\d+))(\.\d{2})?$
Matches a string if it is a valid 24-hour time representations in the format of HH:MM / H:MM / HH / H
Match examples:
- "10:35"
- "9:20"
- "23"
Non-match examples:
- "24:00"
- "20 PM"
Regular expression: (^([0-9]|[0-1][0-9]|[2][0-3]):([0-5][0-9])$)|(^([0-9]|[1][0-9]|[2][0-3])$)
Matches currency values with optional dollar signs, allowing for thousands separators and cents.
Match examples:
- "$3,023,123.34"
- "9,876,453"
- "123456.78"
Non-match examples:
- "4,33,234.34"
- "$1.234"
Regular expression: ^\$?([0-9]{1,3},([0-9]{3},)*[0-9]{3}|[0-9]+)(\.[0-9][0-9])?$
^\$?\d+(\.(\d{2}))?$
Match examples:
- "$2.43"
- "2.02"
- "$2112"
Non-match examples:
- "2.1"
- "$.14"
Regular expression: ^\$?\d+(\.(\d{2}))?$
Fromat check for MM/YY, checks month is 1-12 and any 2 digit year.
Match examples:
- "01/00"
- "12/99"
- "10/30"
Non-match examples:
- "13/00"
- "12/AS"
Regular expression: ((0[1-9])|(1[02]))/\d{2}
This regular expression is designed to match Brazilian phone numbers that include an international dialing code (DDI) without the plus sign, a simple area code (DDD) enclosed in parentheses, a simple local phone number consisting of either 3 or 4 digits, followed by a hyphen, and finally, a 4-digit extension.
Match examples:
- "55(21)123-4567"
- "(11)1234-5678"
- "55(71)4562-2234"
Non-match examples:
- "3434-3432"
- "4(23)232-3232"
Regular expression: ^([0-9]{2})?(\([0-9]{2})\)([0-9]{3}|[0-9]{4})-[0-9]{4}$
This RE validates a path/file of type txt (text file), while insuring the entire string is a fully qualified path and file.
Match examples:
- "c:\file.txt"
- "c:\folder\sub folder\file.txt"
- "\\network\folder\file.txt"
Non-match examples:
- "C:"
- "C:\file.xls"
Regular expression: ^(([a-zA-Z]:)|(\\{2}\w+)\$?)(\\(\w[\w ]*))+\.(txt|TXT)$
Used to validate domain names that start with alphanumeric characters, may contain additional alphanumeric characters, hyphens, and periods in the middle (optionally), and end with one of the specified TLDs (case-insensitive).
Match examples:
- "my.domain.com"
- "regexlib.com"
- "big-reg.com"
Non-match examples:
- ".mydomain.com"
- "regexlib.comm"
Regular expression: ^[a-zA-Z0-9]+([a-zA-Z0-9\-\.]+)?\.(com|org|net|mil|edu|COM|ORG|NET|MIL|EDU)$
Matches numbers that can be positive or negative, may have a decimal point, and can be in scientific notation format
Match examples:
- "123"
- "-123.35"
- "-123.35e-2"
Non-match examples:
- "abc"
- "123.32e"
Regular expression: ^[-+]?[0-9]+[.]?[0-9]*([eE][-+]?[0-9]+)?$
Matches times seperated by either : or . will match a 24 hour time, or a 12 hour time with AM or PM specified. Allows 0-59 minutes, and 0-59 seconds. Seconds are not required.
Match examples:
- "1:01 AM"
- "23:52:01"
- "03.24.36 AM"
Non-match examples:
- "19:31 AM"
- "9:9 PM"
Regular expression: ^((([0]?[1-9]|1[0-2])(:|\.)[0-5][0-9]((:|\.)[0-5][0-9])?( )?(AM|am|aM|Am|PM|pm|pM|Pm))|(([0]?[0-9]|1[0-9]|2[0-3])(:|\.)[0-5][0-9]((:|\.)[0-5][0-9])?))$
Match strings that consist of alphanumeric characters, spaces, periods (dots), hyphens, underscores, and single quotation marks.
Match examples:
- "dony d'gsa"
- "adsfaq9"
- "f231v3"
Non-match examples:
- "^[a-zA-Z0-9\s.\-_']+$"
- "+SDF4324$#*"
Regular expression: ^[a-zA-Z0-9\s.\-_']+$
This regular expression validates that the data entered is a number with a maximum of two integers and two decimals and a minimum of one integer or one decimal.
Match examples:
- "99.99"
- "99"
- ".99"
Non-match examples:
- "999.999"
- "999"
Regular expression: ^\d{0,2}(\.\d{1,2})?$
This will grep for a valid MAC address , with colons seperating octets. It will ignore strings too short or long, or with invalid characters. It will accept mixed case hexadecimal. Use extended grep.
Match examples:
- "01:23:45:67:89:ab"
- "01:23:45:67:89:AB"
- "fE:dC:bA:98:76:54"
Non-match examples:
- "01:23:45:67:89:ab:cd"
- "01:23:45:67:89:Az"
Regular expression: ^([0-9a-fA-F][0-9a-fA-F]:){5}([0-9a-fA-F][0-9a-fA-F])$
This regular expression can match three different patterns:

The exact string "100."
One or two-digit numbers.
Numbers in a specific format with one or two digits, a comma, and one to three digits.
Match examples:
- "12,654"
- "1,987"
- "43,582"
Non-match examples:
- "128,2"
- "12,"
Regular expression: ^100$|^[0-9]{1,2}$|^[0-9]{1,2}\,[0-9]{1,3}$
Correct French DateTime(DD/MM/YYYY OR DD/MM/YYYY HH:MM:SS)
Match examples:
- "12/01/2002"
- "12/01/2002 12:32:10"
- "30/04/2089"
Non-match examples:
- "32/12/2002"
- "12/13/2001"
Regular expression: ^(([0-2]\d|[3][0-1])\/([0]\d|[1][0-2])\/[2][0]\d{2})$|^(([0-2]\d|[3][0-1])\/([0]\d|[1][0-2])\/[2][0]\d{2}\s([0-1]\d|[2][0-3])\:[0-5]\d\:[0-5]\d)$
Matches domain names with subdomains and enforces certain rules such as starting and ending with alphanumeric characters, allowing hyphens in subdomains, and specifying a TLD with 3 to 5 characters.
Match examples:
- "freshmeat.net"
- "123.com"
- "TempLate-toolkKt.orG"
Non-match examples:
- "-dog.com"
- "?boy.net"
Regular expression: ^([a-zA-Z0-9][-a-zA-Z0-9]*[a-zA-Z0-9]\.)+([a-zA-Z0-9]{3,5})$
This one matches all strings that do not contain the single quotation mark (').
Match examples:
- "asljas"
- "%/&amp;89uhuhadjkh"
- "&quot;hi there!&quot;"
Non-match examples:
- "'hi there!'"
- "It's 9 o'clock"
Regular expression: ^[^']*$
Validates a number between 1 and 255.
Match examples:
- "1"
- "108"
- "255"
Non-match examples:
- "01"
- "256"
Regular expression: ^([1-9]|[1-9]\d|1\d{2}|2[0-4]\d|25[0-5])$
Matches non-negative decimal floating points numbers less than 10
Match examples:
- "1.2345"
- "0.00001"
- "7"
Non-match examples:
- "12.2"
- "1.10.1"
Regular expression: ^[0-9](\.[0-9]+)?$