Displaying page
of
pages;
Items to
Title |
Test
Details
Awesome US phone number matching
|
Expression |
(?:\+?1[ .*-]?)?(?:\(? ?)?\d{3}(?: ?\)?)? ?(?:\*|(?:\.|-){1,2})? ?\d{3} ?(?:\*|(?:\.|-){1,2})? ?\d{4}
|
Description |
This regex matches US phone number formats that I found to be commonly used.
This regex is best used on scanning text. If html is present, strip out the html first.
|
Matches |
5555555555 | 555 555 5555 | 555-555-5555 | (555-555-5555 | ( 555-555-5555 | 555) 555-5555 | 555 ) 555- 5555 | 555 ) 555-5555 | (555)555-5555 | (555) 555-5555 | (555) 555 5555 | (555) 555 - 5555 | (555) 555 -5555 | 555 - 555 - 5555 | (555)-555-5555 | 555 555-5555 | 555 -555-5555 | 555.555.5555 | 555-555.5555 | 555. 555.5555 | 555. 555. 5555 | 555*555*5555 | 15555555555 | 1 555 555 5555 | 1-555-555-5555 | 1.555-555-5555 | 1*555*555*5555 | +1 555 555 5555 | +1-555-555-5555 | +1 555-555-5555 | +1.555-555-5555 | +1.555.555.5555 | 1 (555) 555-5555 | +1 (555) 555-5555 | 1 5555555555 | 1.(555-555-555
|
Non-Matches |
anything else
|
Author |
Rating:
Ray Solomon
|
Displaying page
of
pages;
Items to