Country Specific USA

US Social Security Number

Matches US Social Security Numbers (SSN) in format XXX-XX-XXXX

/^(?!000|666|9\d{2})\d{3}-(?!00)\d{2}-(?!0000)\d{4}$/

Type in the box above to test if your input matches the regex pattern.

Test Cases

123-45-6789
987-65-4321
000-12-3456
123-00-6789
123-45-0000
666-12-3456

Tags

#usa #ssn #id #government