# Phone Number Validator - Type, Carrier, Country, Format (`pshivam/phone-number-validator-scraper`) Actor

Validate phone numbers in bulk: valid or not, mobile or landline, country, carrier, location, time zone and E.164 format. Also finds phone numbers in text and on web pages. 240 countries, no API key. Export to Excel, CSV or API.

- **URL**: https://apify.com/pshivam/phone-number-validator-scraper.md
- **Developed by:** [Shivam Prajapati](https://apify.com/pshivam) (community)
- **Categories:** Lead generation, Automation
- **Features:** Limited permissions
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $1.05 / 1,000 records

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.
Since this Actor supports Apify Store discounts, the price gets lower the higher subscription plan you have.

Learn more: https://docs.apify.com/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

## Phone Number Validator - Type, Carrier, Country, Format

**Validate phone numbers in bulk and clean your list in minutes.** Paste numbers in any writing and get, for each one: **valid or not (and why)**, **mobile or landline**, the **country**, the **carrier**, the **place**, the **time zone** and the clean **E.164**, international and national formats. The Actor also **finds phone numbers in a text or on web pages** (contact pages, directories) and validates them. It works offline with Google's libphonenumber data for 240+ countries, so it is fast, needs no API key and costs a fraction of a cent per number. Export to Excel, CSV, JSON or the API.

**Actively maintained.** Last update: 2026-11-13. Every release passes 110+ automated tests, and Apify test-runs it every day.

### What can you use it for?

- **Clean a lead list.** Remove numbers that cannot exist and bring the rest into one format (E.164) for your CRM or dialer.
- **Separate mobile from landline.** Send SMS to mobile numbers only and call the rest. `isMobile` is true, false or empty when the numbering plan cannot tell (US and Canada).
- **Route and segment by country.** Country, calling code, time zone and place for every number, so you call at the right hour.
- **Find numbers on websites.** Give contact page addresses and get the phone numbers on them with the words around each number.
- **Extract numbers from documents and emails.** Paste the text and get every number, validated.
- **Fix exports.** Numbers written as 0044..., without the +, with quotes, with `tel:` or WhatsApp links, or stored as spreadsheet numbers are repaired.

### What data do you get?

One row per number.

| Field | What it is |
|---|---|
| `input` | The entry as you gave it, or the number as written on the page |
| `e164` | The number in E.164 format, for example `+14155552671`. Empty when the number is not valid |
| `isValid` | True when the number exists in the country's numbering plan |
| `isPossible` | True when the length fits the country's numbers |
| `invalidReason` | Why it is not valid: `EMPTY`, `NOT_A_NUMBER`, `TOO_SHORT`, `TOO_LONG`, `MISSING_OR_INVALID_COUNTRY_CODE`, `INVALID_COUNTRY_CODE`, `INVALID_LENGTH`, `LOCAL_NUMBER_ONLY` or `DOES_NOT_MATCH_NUMBERING_PLAN` |
| `regionCode`, `countryName`, `countryCallingCode` | The country code, the country name and the calling code |
| `numberType` | `MOBILE`, `FIXED_LINE`, `FIXED_LINE_OR_MOBILE`, `TOLL_FREE`, `PREMIUM_RATE`, `SHARED_COST`, `VOIP`, `PERSONAL_NUMBER`, `PAGER`, `UAN`, `VOICEMAIL` or `UNKNOWN` |
| `isMobile` | True for mobile, false for other types, empty when it cannot be told |
| `carrier` | The carrier the number range was first given to, where data exists |
| `location` | The place: city or region for landlines, the country for mobile numbers |
| `timeZones` | Time zones of the number's area |
| `international`, `national`, `rfc3966` | The number as `+1 415-555-2671`, `(415) 555-2671` and `tel:+1-415-555-2671` |
| `extension` | The extension given with the number |
| `source` | `list` for a number you gave, `text` for a number found in your text, `url` for a number found on a page |
| `sourceUrl`, `context` | The page a number was found on and the words around it |
| `scrapedAt` | When the record was collected |

#### Example results

```json
{"input": "+919876543210", "e164": "+919876543210", "isValid": true, "isPossible": true, "regionCode": "IN", "countryName": "India", "countryCallingCode": 91, "numberType": "MOBILE", "isMobile": true,
 "carrier": "Airtel", "location": "India", "timeZones": ["Asia/Calcutta"], "international": "+91 98765 43210", "national": "098765 43210", "rfc3966": "tel:+91-98765-43210", "source": "list"}
```

```json
{"input": "+447911123456", "e164": "+447911123456", "isValid": true, "isPossible": true, "regionCode": "GG", "countryName": "Guernsey", "countryCallingCode": 44, "numberType": "MOBILE", "isMobile": true,
 "carrier": "JT", "location": "Guernsey", "timeZones": ["Europe/Guernsey", "Europe/Isle_of_Man", "Europe/Jersey", "Europe/London"], "international": "+44 7911 123456", "national": "07911 123456", "rfc3966": "tel:+44-7911-123456", "source": "list"}
```

```json
{"input": "12", "isValid": false, "isPossible": false, "invalidReason": "MISSING_OR_INVALID_COUNTRY_CODE", "source": "list"}
```

### How to use it

1. Paste your **Phone numbers**, one per line. Set the **Default country** if some numbers are written without + and country code.
2. To find numbers in a text or on pages, fill **Find numbers in a text** or **Find numbers on web pages**.
3. Choose **Only valid numbers** to get and pay for valid numbers only.
4. Press Start. Thousands of numbers take seconds.

#### Input options

| Input | What it does |
|---|---|
| `phoneNumbers` | The numbers to validate, one per line, in any writing. Spreadsheet numbers (14155552671) work too |
| `text` | A text to find numbers in |
| `urls` | Web page addresses to find numbers on. Only the pages you list are read |
| `defaultCountry` | Two-letter country for numbers without + and country code, for example `US` |
| `language` | Language of country and place names. `en` by default, falls back to English |
| `onlyValid` | Return valid numbers only. Invalid entries are not returned and not charged |
| `removeDuplicates` | Return a number once, however it is written. On by default |
| `onlyNew` | Skip numbers that earlier runs already returned |
| `maxItems` | Stop after this many records. 100,000 by default |
| `maxConcurrency` | Web pages read at the same time. 3 by default |
| `secondsBetweenRequests` | Pause between page requests. 0.5 seconds by default |

### How much does it cost?

You pay per record returned, nothing else, with no start fee. 10,000 numbers cost $15 on the Free plan. The first Apify plan includes free monthly credit to try it.

| Plan | Price per 1,000 records |
|---|---|
| Free | $1.50 |
| Bronze | $1.35 |
| Silver | $1.20 |
| Gold | $1.05 |

### Use it via API, on a schedule, or with your tools

```python
from apify_client import ApifyClient

client = ApifyClient("<YOUR_API_TOKEN>")
run = client.actor("pshivam/phone-number-validator-scraper").call(run_input={
    "phoneNumbers": ["+1 415 555 2671", "020 7183 8750", "0049 30 123456"],
    "defaultCountry": "GB",
    "onlyValid": True,
})
for row in client.dataset(run["defaultDatasetId"]).iterate_items():
    print(row["e164"], row["numberType"], row["regionCode"], row["carrier"])
```

**Validate only what is new.** Turn on **Only new records** and schedule the Actor. Numbers that an earlier run returned are skipped and not charged. Connect the dataset to Google Sheets, your CRM, Make, Zapier or n8n with Apify's integrations.

#### Use it in Clay, n8n, Make or Zapier

Use the Actor ID `pshivam/phone-number-validator-scraper` and this input:

```json
{"phoneNumbers": ["+14155552671"], "onlyValid": true}
```

### This validator vs. the alternatives

| | This Actor | Paid lookup APIs | Other Actors |
|---|---|---|---|
| Validity, type, country, formats | Yes | Yes | Yes |
| Live check that the number is active | No | Yes (HLR, $5 to $10 per 1,000) | Some |
| Find numbers in text and on pages | Yes | No | Rarely |
| Repairs 0044..., missing +, tel: links | Yes | Rarely | Some |
| Speed | Thousands per second | Rate limited | Varies |
| Price | $1.50 per 1,000 | $5 to $10 per 1,000 | $1 to $10 per 1,000 |

### Good to know

- **Offline check, no live status.** The Actor checks a number against the numbering plans of 240+ countries. It cannot tell whether the line is connected, who owns it or whether it is on a do-not-call list.
- **The carrier is the original carrier.** `carrier` is the company the number range was first given to. A number that moved to another carrier (number portability) keeps its original carrier here. Carrier data exists for mobile ranges of many countries and is empty for the rest.
- **US and Canada.** The numbering plan does not separate mobile from landline, so `numberType` is `FIXED_LINE_OR_MOBILE` and `isMobile` is empty.
- **Valid means plausible in the numbering plan.** A number that looks right and falls in an unassigned range is invalid. A valid number can still be unused.
- **Web pages.** The Actor reads the pages you list, one request each, and finds numbers in links, text and structured data. Pages that need JavaScript to show their numbers are read as the server sends them.
- **Data source.** Google's libphonenumber (the `phonenumbers` Python port), updated with each Actor release.

### FAQ

#### How do I validate a list of phone numbers?

Paste the numbers into `phoneNumbers`, one per line, set `defaultCountry` if they have no country code, and press Start. Each row says whether the number is valid and why not.

#### How do I know if a number is mobile or landline?

Read `numberType` (`MOBILE`, `FIXED_LINE`, ...) and `isMobile`. For US and Canadian numbers the numbering plan does not tell, so `isMobile` is empty.

#### Can it check whether a number is active or reachable?

No. A live check needs a query to the phone network (HLR) and a paid provider. This Actor validates against the numbering plan, which is the right first step to remove numbers that cannot exist.

#### Can I get the carrier?

Yes, where data exists: `carrier` is the carrier the range was first given to. Ported numbers keep the original carrier.

#### How do I extract phone numbers from a website?

Put the page addresses in `urls`. You get every valid number on each page with `sourceUrl` and the words around it in `context`.

#### How do I extract phone numbers from a text?

Paste the text in `text`. Add `defaultCountry` so numbers without a country code are found.

#### Which format should I use for my CRM?

Use `e164`. It is the standard international format and the same for every way of writing a number.

#### Why is a number I know valid marked invalid?

Check that it has the country code or set `defaultCountry`. If the country is right, the number may be in a range the numbering plan does not list, or the digits may have a typo. `invalidReason` says which.

# Actor input Schema

## `phoneNumbers` (type: `array`):

The numbers to validate, one per line, written in any way: +1 (415) 555-2671, 415-555-2671, 0044 20 7183 8750, tel:+49301234. A number without + needs the default country below.

## `text` (type: `string`):

Paste any text (an email, a document, scraped content) and the Actor finds the phone numbers in it and validates them.

## `urls` (type: `array`):

Web page addresses, for example a contact page. The Actor reads each page and returns the phone numbers on it: links (tel:, WhatsApp), text and structured data. It reads only the pages you list.

## `defaultCountry` (type: `string`):

Two-letter country code for numbers written without + and country code, for example US, GB, DE, IN. Numbers with + or 00 and a country code never need it.

## `language` (type: `string`):

Two-letter language code for the country name, location and carrier, for example en, de, fr, es, ja. Falls back to English.

## `onlyValid` (type: `boolean`):

Return valid numbers only. Invalid entries are not returned and not charged.

## `removeDuplicates` (type: `boolean`):

Return a number once, however it is written (415-555-2671 and +1 415 555 2671 are the same). Numbers found on pages are returned once per page.

## `onlyNew` (type: `boolean`):

Skip numbers that earlier runs already returned, so you validate and pay for new numbers only. The first run works as usual and remembers what it returned, in your key-value store 'phone-number-validator-scraper-only-new'.

## `maxItems` (type: `integer`):

Stop after this many records. You are charged per record.

## `maxConcurrency` (type: `integer`):

How many web pages are read in parallel. Validating numbers needs no web requests.

## `secondsBetweenRequests` (type: `number`):

Pause between web page requests. After a slow-down answer the Actor doubles the pause and switches to Apify Proxy when it can.

## Actor input object example

```json
{
  "phoneNumbers": [
    "+14155552671",
    "+442071838750",
    "07911 123456"
  ],
  "language": "en",
  "onlyValid": false,
  "removeDuplicates": true,
  "onlyNew": false,
  "maxItems": 100,
  "maxConcurrency": 3,
  "secondsBetweenRequests": 0.5
}
```

# Actor output Schema

## `numbers` (type: `string`):

Every number with validity, type, country and carrier.

## `found` (type: `string`):

Numbers found on your pages and in your text, with the page and the words around them.

## `runStats` (type: `string`):

Requests made, time spent and number of records for this run (RUN_STATS record).

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "phoneNumbers": [
        "+14155552671",
        "+442071838750",
        "07911 123456"
    ],
    "maxItems": 100
};

// Run the Actor and wait for it to finish
const run = await client.actor("pshivam/phone-number-validator-scraper").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = {
    "phoneNumbers": [
        "+14155552671",
        "+442071838750",
        "07911 123456",
    ],
    "maxItems": 100,
}

# Run the Actor and wait for it to finish
run = client.actor("pshivam/phone-number-validator-scraper").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "phoneNumbers": [
    "+14155552671",
    "+442071838750",
    "07911 123456"
  ],
  "maxItems": 100
}' |
apify call pshivam/phone-number-validator-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,pshivam/phone-number-validator-scraper"
        }
    }
}
```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/uOi0W4MyntsMKEBfE/builds/KLffIHwYWCXetyhcA/openapi.json
