Phone Number Validation Methods

An Overview of Phone Number 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 data points is the personal phone number. The Pew Research Center reports that approximately 97% of Americans own a mobile phone and that the rest of the world is fast approaching this number. With such a ubiquitous technology, businesses must be able to handle telephone number information to avoid fraud and scamming and ensure they reach their target demographic by verifying the identities associated with the numbers.

Luckily, numerous phone number validation methods exist to ensure 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 number validation methods vary based on budget and accuracy
The phone validation method that is best for you will vary based on your budget and accuracy

Types of phone number validation methods:

Regular Expressions
Line Test
Turning Test
Database Check
Phone Number Verification
Real-time Phone Number Validation

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 can be performed asynchronously using AJAX methods while the user fills out the web form. Once a properly formatted number is submitted, it can be tested without interrupting the user.

Pros:

It can be used for both mobile and landline numbers
It can be used for international numbers

Cons:

It 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. We can ensure a live number by employing a reverse Turing test. 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. The phone number is considered live if we get the desired response (usually by pressing a certain number).

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 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:

It does not provide additional details about the number or subscribers.

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 uses telecommunications data to provide information, such as whether the number is a mobile or landline and the carrier’s name. This method combines the speed of the database method with the accuracy of the line test, making it an effective option.

Pros:

The most accurate validation available
Telco data
Up-to-the-minute data
Easily integrated into web form using our Phone Validator API
Great for updating existing lists and database
It also includes phone line type – landline or cell, and carrier ID

Cons:

Unlike the regular expression method, users are charged per validation.

Before you go...

Are you currently using a
phone validation service?

Close
Scroll to Top