Test, validate and match regular expressions
This regular expression matches 10-digit phone numbers, accommodating common formatting characters such as parentheses, hyphens, periods, or spaces. It captures a sequence of three digits, another three digits, and a final four digits, allowing optional non-digit separators between them. It is highly useful for extracting or validating loosely formatted North American phone numbers from large bodies of text or user inputs.