Curated library of common regex patterns for emails, URLs, dates, numbers, and more. Test patterns inline.
Validates standard email addresses
/^[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,}$/Matches HTTP/HTTPS URLs
/https?:\/\/(www\.)?[-a-zA-Z0-9@:%._\+~#=]{1,256}\.[a-zA-Z0-9()]{1,6}\b([-a-zA-Z0-9()@:%_\+.~#?&//=]*)/Validates IPv4 addresses
/^((25[0-5]|(2[0-4]|1\d|[1-9]|)\d)\.?\b){4}$/Validates full IPv6 addresses
/^([0-9a-fA-F]{1,4}:){7}[0-9a-fA-F]{1,4}$/Matches US phone numbers in various formats
/^\+?1?[-.\s]?\(?\d{3}\)?[-.\s]?\d{3}[-.\s]?\d{4}$/Matches international phone numbers (E.164)
/^\+?[1-9]\d{1,14}$/Matches hex color codes (3 or 6 digits)
/^#?([a-fA-F0-9]{6}|[a-fA-F0-9]{3})$/Matches opening and closing HTML tags
/<\/?[a-z][\s\S]*?>/giMatches URL slugs (lowercase, hyphens)
/^[a-z0-9]+(?:-[a-z0-9]+)*$/Validates UUID version 4
/^[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$/iMatches JSON string values
/"(?:[^"\\]|\\.)*"/gMatches positive and negative integers
/^-?\d+$/Matches decimal numbers
/^-?\d+\.\d+$/Matches numbers in scientific notation
/^-?\d+\.?\d*[eE][+-]?\d+$/Matches US dollar amounts
/^\$?\d{1,3}(,\d{3})*(\.\d{2})?$/Matches percentage values
/^-?\d+(\.\d+)?%$/Matches ISO date format
/^\d{4}-(0[1-9]|1[0-2])-(0[1-9]|[12]\d|3[01])$/Matches US date format
/^(0[1-9]|1[0-2])\/(0[1-9]|[12]\d|3[01])\/\d{4}$/Matches 24-hour time
/^([01]\d|2[0-3]):([0-5]\d):([0-5]\d)$/Matches ISO 8601 datetime format
/^\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(\.\d+)?(Z|[+-]\d{2}:\d{2})?$/At least 8 chars, uppercase, lowercase, digit, special char
/^(?=.*[a-z])(?=.*[A-Z])(?=.*\d)(?=.*[@$!%*?&])[A-Za-z\d@$!%*?&]{8,}$/Matches Visa card numbers
/^4[0-9]{12}(?:[0-9]{3})?$/Matches US SSN format
/^(?!000|666|9\d{2})\d{3}-(?!00)\d{2}-(?!0000)\d{4}$/Matches CSS property declarations
/[a-z-]+\s*:\s*[^;]+;/gMatches JS variable declarations
/\b(const|let|var)\s+([a-zA-Z_$][a-zA-Z0-9_$]*)\b/gMatches ES module imports
/^import\s+.*\s+from\s+['"].*['"]/gmCurated library of common regex patterns for emails, URLs, dates, numbers, and more. Test patterns inline.
Subscribe to get notified about new tools and features.
Format, validate, and beautify your JSON data online. Minify or prettify JSON with syntax highlighting.
Encode text to Base64 or decode Base64 strings online. Supports UTF-8 text and file encoding.
Test and debug regular expressions online with real-time matching. Highlight matches and view groups.
Generate SHA-1, SHA-256, SHA-384, SHA-512 hashes from text online. Free cryptographic hash generator.