HomeRegex Generators
Regex Generators
Templates to build your own regex.
10 Tools Available
Integer Range 0-99
Matches 0-99.
/^[0-9]$|^[1-9][0-9]$/
Date YYYY-MM-DD
Matches standard date.
/^\d{4}-\d{2}-\d{2}$/
Time HH:MM
Matches 24h time.
/^([0-1]?[0-9]|2[0-3]):[0-5][0-9]$/
Alphanumeric String
Matches alpha-num only.
/^[a-zA-Z0-9]+$/
Hex Color Code
Matches hex colors.
/^#([A-Fa-f0-9]{6}|[A-Fa-f0-9]{3})$/
UUID GUID
Matches standard UUID.
/^[0-9a-fA-F]{8}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{12}$/
Slug Pattern
Matches URL slugs.
/^[a-z0-9]+(?:-[a-z0-9]+)*$/
Filename Extension
Matches specific extensions.
/^.+\.(txt|pdf|docx)$/
Semantic Version
Matches 1.0.0.
/^\d+\.\d+\.\d+$/
CSS Hex
Matches CSS Hex colors.
/^#([A-Fa-f0-9]{3}){1,2}$/