# Phone Number Validator - Bulk International Phone Validation (`santamaria-automations/phone-validator`) Actor

Validate and format phone numbers in bulk. Detect country, number type (mobile/landline/VoIP), carrier, timezone, and geographic region. Powered by Google's libphonenumber — the industry standard used by major platforms. Perfect for CRM cleanup, lead validation, and SMS campaigns.

- **URL**: https://apify.com/santamaria-automations/phone-validator.md
- **Developed by:** [Alessandro Santamaria](https://apify.com/santamaria-automations) (community)
- **Categories:** Lead generation, Automation
- **Stats:** 6 total users, 2 monthly users, 100.0% runs succeeded, NaN bookmarks
- **User rating**: No ratings yet

## Pricing

from $1.00 / 1,000 phone number validateds

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.

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

## What's an Apify Actor?

Actors are a software tools running on the Apify platform, for all kinds of web data extraction and automation use cases.
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.
Actors are written with capital "A".

## 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.
The best way to integrate Actors is as follows.

In JavaScript/TypeScript projects, use official [JavaScript/TypeScript client](https://docs.apify.com/api/client/js.md):

```bash
npm install apify-client
```

In Python projects, use official [Python client library](https://docs.apify.com/api/client/python.md):

```bash
pip install apify-client
```

In shell scripts, use [Apify CLI](https://docs.apify.com/cli/docs.md):

````bash
# MacOS / Linux
curl -fsSL https://apify.com/install-cli.sh | bash
# Windows
irm https://apify.com/install-cli.ps1 | iex
```bash

In AI frameworks, you might use the [Apify MCP server](https://docs.apify.com/platform/integrations/mcp.md).

If your project is in a different language, use the [REST API](https://docs.apify.com/api/v2.md).

For usage examples, see the [API](#api) section below.

For more details, see Apify documentation as [Markdown index](https://docs.apify.com/llms.txt) and [Markdown full-text](https://docs.apify.com/llms-full.txt).


# README

## Phone Number Validator - Bulk International Validation at $0.001

Validate, format and enrich phone numbers in bulk — **5x cheaper than Twilio Lookup** ($0.005/number), no external API dependencies, no rate limits. Powered by the same **industry-standard phone parser that powers WhatsApp, Android, Skype and every major CRM**, so you get the exact same results the telecoms industry trusts.

Upload a messy list of international numbers in any format and get back clean E.164-normalized records with country, number type, carrier, timezone and region.

### What you get

- **Any input format accepted** — `+49 30 12345678`, `030 12345678`, `(212) 555-0123`, `0175/987 65 43`
- **Country detection** — ISO code, country name, dialing code
- **Number type** — mobile, landline, VoIP, toll-free, premium-rate, shared-cost, pager, UAN, voicemail
- **Carrier lookup** — mobile operator name where available
- **Timezone mapping** — IANA timezones from the phone prefix
- **Geographic region** — city or area name (e.g. "Berlin", "Zurich", "London")
- **Multi-format output** — E.164, International, National, RFC3966
- **Strict + lenient checks** — both `is_valid` and `is_possible` returned
- **100% local validation** — no external API calls, no rate limits, no proxy needed

### Use with AI Agents (MCP)

Connect this actor to any MCP-compatible AI client — Claude Desktop, Claude.ai, Cursor, VS Code, LangChain, LlamaIndex, or custom agents.

**Apify MCP server URL:**

````

https://mcp.apify.com?tools=santamaria-automations/phone-validator

````

**Example prompt once connected:**

> "Use `phone-validator` to process data with phone validator. Return results as a table."

Clients that support dynamic tool discovery (Claude.ai, VS Code) will receive the full input schema automatically via `add-actor`.

### Example output

**German mobile**
```json
{
  "input": "0175 9876543",
  "is_valid": true,
  "country_iso": "DE",
  "country_name": "Germany",
  "country_code": 49,
  "e164": "+491759876543",
  "international": "+49 175 9876543",
  "national": "0175 9876543",
  "number_type": "MOBILE",
  "carrier": "Telekom Deutschland",
  "timezone": ["Europe/Berlin", "Europe/Busingen"],
  "location": "Germany"
}
````

**Swiss landline**

```json
{
  "input": "+41 44 123 4567",
  "is_valid": true,
  "country_iso": "CH",
  "country_name": "Switzerland",
  "e164": "+41441234567",
  "number_type": "FIXED_LINE",
  "timezone": ["Europe/Zurich"],
  "location": "Zurich"
}
```

**Invalid input**

```json
{
  "input": "notaphone",
  "is_valid": false,
  "is_possible": false,
  "error": "the phone number supplied is not a number"
}
```

### How to use

Paste your phone numbers into the `phoneNumbers` input, set `defaultRegion` to the country most of your numbers come from (so numbers without a `+` country code parse correctly), and run. One clean record per number comes back.

#### Input

| Parameter | Description | Default |
|-----------|-------------|---------|
| `phoneNumbers` | Phone numbers to validate (any format) | *(required)* |
| `defaultRegion` | ISO-3166-1 alpha-2 country for parsing numbers without `+` prefix | `DE` |
| `formats` | Formats to include: `E164`, `INTERNATIONAL`, `NATIONAL`, `RFC3966` | `["E164","INTERNATIONAL","NATIONAL"]` |

### Use cases

- **CRM hygiene** — normalize messy HubSpot/Salesforce/Pipedrive phones to E.164 before migration or dedup
- **SMS campaign pre-flight** — filter out invalid and non-mobile numbers before an SMS blast to avoid wasted sends
- **Dialer routing** — route mobiles to SMS, landlines to your outbound dialer, premium-rate to a block list
- **Fraud detection at signup** — flag impossible numbers and geo-mismatches (ISO country vs account country)
- **Timezone-aware outreach** — use timezone data to call prospects at the right local hour
- **Compliance reporting** — count EU vs non-EU numbers for GDPR audits without writing parsing code
- **Lead enrichment** — append carrier, type and location to every phone in your pipeline

### Pricing

| Event | Price |
|-------|-------|
| Actor start | $0.001 |
| Per number validated | $0.001 |

**Example**: Validate 10,000 numbers = **$10.01** (vs Twilio Lookup at ~$50)

| Numbers | Cost |
|---------|------|
| 1,000 | $1.00 |
| 10,000 | $10.00 |
| 100,000 | $100.00 |

No proxy costs. No external API fees. No hidden markups.

### Issues & Feedback

Found a bug or have a feature request? [Open an issue on the Issues tab](https://console.apify.com/actors/Ruobvx94jpuPcCm2d/issues) — we respond within 24 hours.

### Related Actors

- [Email Verifier](https://apify.com/santamaria-automations/email-verifier-scraper) — bulk email validation at $0.002 per address
- [Domain WHOIS & DNS Lookup](https://apify.com/santamaria-automations/domain-whois-dns-scraper) — bulk WHOIS, DNS and email provider detection
- [Website Tech Stack Detector](https://apify.com/santamaria-automations/website-tech-detector-scraper) — identify CMS, frameworks and 2000+ technologies
- [Website Contact Extractor](https://apify.com/santamaria-automations/website-contact-extractor) — extract emails, phones and social URLs from any website
- [Website Intelligence Extractor](https://apify.com/santamaria-automations/website-intelligence-extractor) — full company summary, products, services and team
- [Google Maps Scraper](https://apify.com/santamaria-automations/google-maps-scraper) — discover businesses worldwide with contact details

# Actor input Schema

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

List of phone numbers to validate. Any format accepted: '+49 30 12345678', '030 12345678', '(212) 555-0123'. For numbers without a country code, the defaultRegion is used to parse them.

## `defaultRegion` (type: `string`):

ISO 3166-1 alpha-2 country code (e.g., 'DE', 'US', 'CH', 'GB', 'FR'). Used to parse phone numbers that do not include a country code (e.g., '030 12345678' is parsed as German when defaultRegion='DE').

## `formats` (type: `array`):

Which formatted representations to include in the output. E164 is the internationally unique format recommended for storage.

## Actor input object example

```json
{
  "phoneNumbers": [
    "+49 30 12345678",
    "030 12345678",
    "0175 9876543",
    "+41 44 123 4567",
    "+1 212 555 0123",
    "+44 20 7946 0958"
  ],
  "defaultRegion": "DE",
  "formats": [
    "E164",
    "INTERNATIONAL",
    "NATIONAL"
  ]
}
```

# Actor output Schema

## `phoneNumbers` (type: `string`):

Dataset of validated phone numbers with full enrichment

# 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": [
        "+49 30 12345678",
        "030 12345678",
        "0175 9876543",
        "+41 44 123 4567",
        "+1 212 555 0123",
        "+44 20 7946 0958"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("santamaria-automations/phone-validator").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": [
        "+49 30 12345678",
        "030 12345678",
        "0175 9876543",
        "+41 44 123 4567",
        "+1 212 555 0123",
        "+44 20 7946 0958",
    ] }

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

# Fetch and print Actor results from the run's dataset (if there are any)
print("💾 Check your data here: https://console.apify.com/storage/datasets/" + run["defaultDatasetId"])
for item in client.dataset(run["defaultDatasetId"]).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": [
    "+49 30 12345678",
    "030 12345678",
    "0175 9876543",
    "+41 44 123 4567",
    "+1 212 555 0123",
    "+44 20 7946 0958"
  ]
}' |
apify call santamaria-automations/phone-validator --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "command": "npx",
            "args": [
                "mcp-remote",
                "https://mcp.apify.com/?tools=santamaria-automations/phone-validator",
                "--header",
                "Authorization: Bearer <YOUR_API_TOKEN>"
            ]
        }
    }
}

```

## OpenAPI specification

```json
{
    "openapi": "3.0.1",
    "info": {
        "title": "Phone Number Validator - Bulk International Phone Validation",
        "description": "Validate and format phone numbers in bulk. Detect country, number type (mobile/landline/VoIP), carrier, timezone, and geographic region. Powered by Google's libphonenumber — the industry standard used by major platforms. Perfect for CRM cleanup, lead validation, and SMS campaigns.",
        "version": "1.0",
        "x-build-id": "itictzzRBpPeopAhD"
    },
    "servers": [
        {
            "url": "https://api.apify.com/v2"
        }
    ],
    "paths": {
        "/acts/santamaria-automations~phone-validator/run-sync-get-dataset-items": {
            "post": {
                "operationId": "run-sync-get-dataset-items-santamaria-automations-phone-validator",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor, waits for its completion, and returns Actor's dataset items in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        },
        "/acts/santamaria-automations~phone-validator/runs": {
            "post": {
                "operationId": "runs-sync-santamaria-automations-phone-validator",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor and returns information about the initiated run in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/runsResponseSchema"
                                }
                            }
                        }
                    }
                }
            }
        },
        "/acts/santamaria-automations~phone-validator/run-sync": {
            "post": {
                "operationId": "run-sync-santamaria-automations-phone-validator",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor, waits for completion, and returns the OUTPUT from Key-value store in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        }
    },
    "components": {
        "schemas": {
            "inputSchema": {
                "type": "object",
                "required": [
                    "phoneNumbers"
                ],
                "properties": {
                    "phoneNumbers": {
                        "title": "Phone Numbers",
                        "type": "array",
                        "description": "List of phone numbers to validate. Any format accepted: '+49 30 12345678', '030 12345678', '(212) 555-0123'. For numbers without a country code, the defaultRegion is used to parse them.",
                        "items": {
                            "type": "string"
                        }
                    },
                    "defaultRegion": {
                        "title": "Default Region",
                        "type": "string",
                        "description": "ISO 3166-1 alpha-2 country code (e.g., 'DE', 'US', 'CH', 'GB', 'FR'). Used to parse phone numbers that do not include a country code (e.g., '030 12345678' is parsed as German when defaultRegion='DE').",
                        "default": "DE"
                    },
                    "formats": {
                        "title": "Output Formats",
                        "uniqueItems": true,
                        "type": "array",
                        "description": "Which formatted representations to include in the output. E164 is the internationally unique format recommended for storage.",
                        "items": {
                            "type": "string",
                            "enum": [
                                "E164",
                                "INTERNATIONAL",
                                "NATIONAL",
                                "RFC3966"
                            ]
                        },
                        "default": [
                            "E164",
                            "INTERNATIONAL",
                            "NATIONAL"
                        ]
                    }
                }
            },
            "runsResponseSchema": {
                "type": "object",
                "properties": {
                    "data": {
                        "type": "object",
                        "properties": {
                            "id": {
                                "type": "string"
                            },
                            "actId": {
                                "type": "string"
                            },
                            "userId": {
                                "type": "string"
                            },
                            "startedAt": {
                                "type": "string",
                                "format": "date-time",
                                "example": "2025-01-08T00:00:00.000Z"
                            },
                            "finishedAt": {
                                "type": "string",
                                "format": "date-time",
                                "example": "2025-01-08T00:00:00.000Z"
                            },
                            "status": {
                                "type": "string",
                                "example": "READY"
                            },
                            "meta": {
                                "type": "object",
                                "properties": {
                                    "origin": {
                                        "type": "string",
                                        "example": "API"
                                    },
                                    "userAgent": {
                                        "type": "string"
                                    }
                                }
                            },
                            "stats": {
                                "type": "object",
                                "properties": {
                                    "inputBodyLen": {
                                        "type": "integer",
                                        "example": 2000
                                    },
                                    "rebootCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "restartCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "resurrectCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "computeUnits": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            },
                            "options": {
                                "type": "object",
                                "properties": {
                                    "build": {
                                        "type": "string",
                                        "example": "latest"
                                    },
                                    "timeoutSecs": {
                                        "type": "integer",
                                        "example": 300
                                    },
                                    "memoryMbytes": {
                                        "type": "integer",
                                        "example": 1024
                                    },
                                    "diskMbytes": {
                                        "type": "integer",
                                        "example": 2048
                                    }
                                }
                            },
                            "buildId": {
                                "type": "string"
                            },
                            "defaultKeyValueStoreId": {
                                "type": "string"
                            },
                            "defaultDatasetId": {
                                "type": "string"
                            },
                            "defaultRequestQueueId": {
                                "type": "string"
                            },
                            "buildNumber": {
                                "type": "string",
                                "example": "1.0.0"
                            },
                            "containerUrl": {
                                "type": "string"
                            },
                            "usage": {
                                "type": "object",
                                "properties": {
                                    "ACTOR_COMPUTE_UNITS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_WRITES": {
                                        "type": "integer",
                                        "example": 1
                                    },
                                    "KEY_VALUE_STORE_LISTS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_INTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_EXTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_SERPS": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            },
                            "usageTotalUsd": {
                                "type": "number",
                                "example": 0.00005
                            },
                            "usageUsd": {
                                "type": "object",
                                "properties": {
                                    "ACTOR_COMPUTE_UNITS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_WRITES": {
                                        "type": "number",
                                        "example": 0.00005
                                    },
                                    "KEY_VALUE_STORE_LISTS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_INTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_EXTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_SERPS": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            }
                        }
                    }
                }
            }
        }
    }
}
```
