Toggle navigation
Regex DB
Search
Notice: This site is currently in beta. It may break at any time, and all URLs are subject to change.
Number > Real number
Favorite
Matches a real number.
Test with sample data
Normal
Quoted
/^(?:-(?:[1-9](?:\d{0,2}(?:,\d{3})+|\d*))|(?:0|(?:[1-9](?:\d{0,2}(?:,\d{3})+|\d*))))(?:.\d+|)$/
'/^(?:-(?:[1-9](?:\\d{0,2}(?:,\\d{3})+|\\d*))|(?:0|(?:[1-9](?:\\d{0,2}(?:,\\d{3})+|\\d*))))(?:.\\d+|)$/'
Sample Matches
Text
Result
-1
Group #0
-1
match
-1,000
Group #0
-1,000
match
-1,000.01
Group #0
-1,000.01
match
-1.01
Group #0
-1.01
match
0
Group #0
0
match
0.01
Group #0
0.01
match
1
Group #0
1
match
1.01
Group #0
1.01
match
100,121
Group #0
100,121
match
100,121.01
Group #0
100,121.01
match
1000
Group #0
1000
match
1000.01
Group #0
1000.01
match
-0.
no match
01
no match
1.
no match
100,1213.
no match
Categories
[No Folder]
Base64 encoded string (RFC 4648)
Copyright year
Copyright year (html)
CSV
Dice roll spec
Identifier (in C-like programming languages)
LDAP query
SemVer
Vehicle Identification Number (VIN)
Boolean
Boolean value
False value
True value
Credit Card
American Express (advanced)
American Express (simple)
Discover (advanced)
Discover (simple)
MasterCard (advanced)
MasterCard (simple)
Visa (advanced)
Visa (simple)
CSS
CSS class
Hex color
Hex color (6 digit)
hsl()
hsla()
rgb()
rgba()
DateTime
Date MMDDYYY
Date with optional time (ISO 8601)
Date YYYYMMDD
Day of week
Duration (ISO 8601) - Find
Duration (ISO 8601) - Validate
Leap year
Name of month
Repeating interval (ISO 8601) (R<n>/<start>/<duration>)
Time
Time (00-24)
Time (h:m:s)
Email
Email address (advanced)
Email address (Blink/Chrome)
Email address (Gecko/Firefox)
Email address (PHP)
Email address (RFC 822)
Email address (simple)
Email address (Webkit/Safari)
Email address list
HTML5
Character entity reference
Duration (1d 2m ...)
Duration (ISO 8601)
Global date/time
Local date/time
Month
Time
Timezone offset
Week
Yearless date
ID
ISBN-10
ISBN-13
MAC address (advanced)
MAC address (simple)
SSN (loose)
SSN (strict)
UUID/GUID
UUID/GUID with optional braces
Number
Dollar value
File Size
Floating point
Floating point with exponent
Integer (loose, commas not allowed)
Integer (strict, commas allowed)
Natural number
Real number
(current)
Roman numeral
Whole number
Phone
Phone number
Phone number (7+ digits)
Postal Code
Australia
Australia (simple)
Belgium
Brazil
Canada
Canada (simple)
Denmark
France
Germany
Greenland
Italy
Netherlands
Netherlands (simple)
Norway
Spain
Switzerland
UK
UK (simple)
USA
Quoted String
'Single quotes' with backslash escape
'Single quotes' with quote escape
'Single' or "double" quotes with backslash escape
"Double quotes" with backslash escape
"Double quotes" with quote escape
String
Invalid UTF-8 character
Valid UTF-8 string
URL
IPv4 (RFC 3986)
IPv4 (simple)
IPv6 (RFC 2732) v1
IPv6 (RFC 2732) v2
URL encoded string
Valid URL (RFC 3986)
Valid URL (RFC 3986) (Advanced)