Phone Number Validation Methods

Real Phone ValidationPhone Number Validation

An Overview of Phone Validation Methods

The vast proliferation of personal data in the last few decades has made accurate and precise data gathering and validation more important than ever for business owners. One of the most useful of these data points is the personal phone number. The Pew Research Center reports that approximately 90% of Americans own a mobile phone and that the rest of the world is fast approaching this number. With such a ubiquitous technology it is critical for businesses to be able to handle telephone number information in order to avoid fraud, scamming and to make certain that they reach their target demographic by verifying the identities associated with the numbers.

Luckily, numerous methods exist for ensuring the validity of personal phone numbers. These methods range from simple checks against publicly available data to directly polling the number to determine whether or not it is active. Here we will review some of the common methods in use and the advantages and disadvantages of each.

Phone validation methods vary based on budget and accuracy

Regular Expressions

Regular expressions are sequences of characters that define a search pattern. In the context of phone number validation they’re used to determine whether or not a given phone number is properly formatted according to a given specification. For instance, a web form might use regular expressions to check whether a phone number entered by a user matches the NANP (North American Numbering Plan) format: NXX-NXX-XXXX where N is any number between 2 and 9 and X is any number between 0 and 9. Generally, regular expressions are used in tandem with another verification method as these only ensure adherence to a desired format.

Pros:
  • Filters out improperly formatted numbers
  • Very fast response times
  • No cost associated with verification
Cons:
  • Does not provide additional information (active/inactive, landline/mobile …)

Line Test

This method tests the line directly by calling the number under consideration and analyzing the response. Different tones and signals received during this call give information about the status of the number and its current use. This test is rather slow but fortunately can be performed asynchronously using AJAX methods while the user fills out the web form. That is, once a properly formatted number is submitted it can be tested without interrupting the user.

Pros:
  • Can be used for both mobile and landline numbers
  • Can be used for international numbers
Cons:
  • Is relatively slow (sometimes taking up to 30 seconds)
  • Cannot ensure a proper number format (should be combined with a regular expression)

Turing Test

The Turing test (named after its inventor, Alan Turing) was devised to distinguish between the behavior of computers and that of humans. The original idea was that a human would pass notes to two different entities (one human and one computer) and try to determine which one was the computer. By employing a sort of reverse Turing test we can ensure that we have a live number. This means we program the computer to contact a number and request a response to determine if the entity on the other end is a human rather than another computer. If we get the desired response (usually pressing a certain number) then the phone number is considered live.

Pros:
  • Effective at ensuring that the number belongs to a human
Cons:
  • Slower than line test as call time depends on the response of the owner of the number
  • Cannot ensure a proper number format (should be combined with a regular expression)

Database Check

This method of number validation checks the number provided against a database of personal information gathered from public sources. Depending on the depth and quality of the database the check may be able to reveal a great deal of information about the number. This method is quite fast but the quality and reliability of the results depend on the database used.

Pros:
  • Very fast response times
  • Useful for fraud prevention as it may provide a wealth of detail (owner, address, email…)
Cons:
  • Depends on the quality of the database used
  • Not effective for Pay-as-you-go phones (they rarely have a registered owner)
  • No single database exists to handle all international subscriber lines

Phone Number Verification

(Two-step Authorization)

This method verifies the legitimacy of the phone subscriber. The subscriber submits a number they wish to use and they are then provided with an authorization token. A call is made to the provided number and the token is requested. This ensures the service subscriber is either registered under the given number or at least has access to it. Examples of this method can be seen in services like Google Voice and some financial institutions use variants of this method to certify a genuine user.

Pros:
  • Ensures the subscriber either owns or operates the phone number provided
Cons:
  • Does not provide additional details about the number or subscriber

Real-time Phone Number Validation

(What we do)

Real-time phone number validation is done by pinging the data used by the switch of the phone number provided to check if phone number is active / connected. It also makes use of telecommunications data to provide information such as whether the number is a mobile or landline, and the name of the carrier. This method combines the speed of the database method with the accuracy of the line test making it an effective option.

Pros:
Cons:
  • Unlike the regular expression method users are charged per validation

Ready for the most accurate validation available?

Real Phone Validation silently touches the phone switch and uses the telco data returned to identify disconnected and invalid phone numbers. In real-time or batch we offer a validation solution to fit your needs.