# NPI Healthcare Provider Search — US Doctors & Clinics Leads (`openregistry/npi-healthcare-provider-search`) Actor

Build lists of US doctors, dentists, nurses, clinics and hospitals from the public NPI registry (NPPES API). Filter by specialty, state, city, ZIP and type. Goes past the 1,200-result limit by splitting searches automatically.

- **URL**: https://apify.com/openregistry/npi-healthcare-provider-search.md
- **Developed by:** [Mahé Perrin](https://apify.com/openregistry) (community)
- **Categories:** Lead generation, Business
- **Features:** Limited permissions
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

$1.50 / 1,000 provider delivereds

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

## NPI Healthcare Provider Search — US Doctors & Clinics Leads

Build targeted lists of US healthcare providers — physicians, dentists, nurse practitioners, therapists, pharmacies, clinics, hospitals — from the **public NPI registry** (NPPES), read through its documented API (`npiregistry.cms.hhs.gov/api`, version 2.1).

No login, no cookies, no proxy, no browser: the Actor only calls a public API, so runs are quick and stay stable.

This is an independent tool. It is not affiliated with, endorsed by or operated by CMS or any government body.

### Why this one

- **Goes past the 1,200-result ceiling.** The registry never returns more than 1,200 providers for one search. When a search hits that ceiling, the Actor splits it by ZIP code prefix on its own and keeps going. *All dentists in Texas* comes back complete, not truncated.
- **Practice location, not mailing address.** State, city and ZIP filters apply to where the provider works. A billing office in another state does not pollute your list.
- **Several specialties, states and cities in one run**, de-duplicated by NPI.
- **Primary specialty filter**: drop providers who only list your target specialty as a secondary one. Skipped providers are not charged.
- **Flat, CRM-ready rows**: one line per provider, practice phone and address in plain columns.

### What you get for each provider

| Field | Example |
|---|---|
| `npi`, `providerType` | 1932307261, individual |
| `name`, `firstName`, `lastName`, `credential` | WILLIAM PETER ABIDE Jr., M.D. |
| `organizationName`, `authorizedOfficial` | for clinics and hospitals: legal name, official's name, title and phone |
| `primaryTaxonomy`, `primaryTaxonomyCode` | Internal Medicine, Cardiovascular Disease — 207RC0000X |
| `licenseNumber`, `licenseState`, `taxonomies` | P5252, TX, plus every other specialty |
| `practiceAddress`, `practiceCity`, `practiceState`, `practicePostalCode` | 1330 WONDER WORLD DR, B-108 — SAN MARCOS, TX 78666 |
| `practicePhone`, `practiceFax` | 512-396-5603 |
| `mailingAddress`, `mailingCity`, `mailingState`, `mailingPhone` | mailing address when it differs |
| `otherPracticeLocations`, `otherNames`, `identifiers`, `endpoints` | secondary locations, DBA names, other IDs, Direct addresses |
| `enumerationDate`, `lastUpdated`, `status` | 2007-07-09, 2022-01-21, active |
| `sourceUrl` | link to the provider's page in the registry |

### Typical uses

- B2B prospecting for medical devices, dental supplies, healthcare software, staffing and billing services.
- Territory planning: count and list every cardiologist in a metro area by ZIP prefix.
- Enrich or verify a CRM: pass a list of NPI numbers and get the current registry record.
- Credentialing and compliance checks: confirm an NPI, its specialty and license number.
- Spot new practices: sort the result by `enumerationDate`.

### Input

Give at least one of: a specialty, a city, a ZIP code, a name or NPI numbers. The registry refuses a search by state or provider type alone, so combine a state with something else.

```json
{
  "taxonomies": ["Dentist", "Orthodontics"],
  "states": ["TX"],
  "cities": ["Austin", "Round Rock"],
  "providerType": "individual",
  "primaryTaxonomyOnly": true,
  "maxResults": 2000
}
```

Specialty names follow the healthcare provider taxonomy: *Family Medicine*, *Nurse Practitioner*, *Physical Therapist*, *Chiropractor*, *Pharmacy*, *Clinic/Center*, *General Acute Care Hospital*… If the registry does not know a specialty name, the run fails with its message instead of returning an empty list. Name filters accept a trailing `*` after two letters (`smi*`).

Lists are combined: 2 specialties × 3 cities = 6 searches, at most 500 searches per run.

### Limits to know

- The registry holds what providers declared. E-mail addresses and websites are not part of it and are not returned; the only electronic addresses are the health-information-exchange endpoints some providers publish.
- A provider can match a location filter through one of its secondary practice locations (`otherPracticeLocations`), so a few rows show a primary practice address elsewhere.
- Automatic splitting works on US ZIP codes. A search that still exceeds 1,200 providers inside a single 5-digit ZIP cannot be split further; the Actor tells you.
- Splitting a very large search takes many API calls (about 100 for a whole state). The Actor paces its calls to stay gentle with the public API, so a 50,000-provider run takes several minutes.

### Personal data

The NPI registry is published by the US government under the Freedom of Information Act, and it includes business contact details of individual practitioners. This Actor returns only what the registry publishes. You are responsible for how you use the data, including compliance with the laws that apply to your outreach (for example CAN-SPAM, TCPA and state privacy laws).

### Pricing

Pay per provider delivered. Skipped and duplicate providers are never charged, and `maxResults` caps the bill.

### Step-by-step guide

- [How to download NPI registry data by specialty and state (past the 1,200-result limit)](https://app.mahedesk.com/outils/guides/download-npi-registry-by-specialty-state/)

# Actor input Schema

## `taxonomies` (type: `array`):

Specialty names as used in the healthcare taxonomy, e.g. Dentist, Family Medicine, Cardiovascular Disease, Nurse Practitioner, Physical Therapist, Pharmacy, General Acute Care Hospital. Each specialty is searched separately.

## `states` (type: `array`):

Two-letter state codes, e.g. TX, CA, NY. A state must be combined with a specialty, a city, a ZIP code or a name (the registry does not accept a state alone).

## `cities` (type: `array`):

City names, e.g. Austin. Combine with a state to avoid homonyms.

## `postalCodes` (type: `array`):

5-digit ZIP codes, or the first 2 to 4 digits to cover an area (787 matches every ZIP starting with 787).

## `providerType` (type: `string`):

Individuals hold an NPI-1, organizations an NPI-2.

## `firstName` (type: `string`):

Individuals only. Add \* after at least 2 letters for a prefix search, e.g. jo\*.

## `lastName` (type: `string`):

Individuals only. Add \* after at least 2 letters for a prefix search, e.g. smi\*.

## `organizationName` (type: `string`):

Organizations only. Add \* after at least 2 letters for a prefix search, e.g. mayo\*.

## `npiNumbers` (type: `array`):

Look up specific 10-digit NPI numbers (to enrich a list you already have). When filled, the other filters are ignored.

## `addressPurpose` (type: `string`):

State, city and ZIP filters match the practice location by default, so you get providers who actually work in the area.

## `primaryTaxonomyOnly` (type: `boolean`):

Keep only providers whose primary specialty matches the one you searched. Providers who merely list it as a secondary specialty are skipped and not charged.

## `autoSplit` (type: `boolean`):

The registry returns at most 1,200 providers per search. When a search hits that limit, the Actor splits it by ZIP code prefix and keeps going until your maximum is reached.

## `maxResults` (type: `integer`):

The run stops once this many providers are delivered, so you control the cost.

## Actor input object example

```json
{
  "taxonomies": [
    "Dentist"
  ],
  "states": [
    "TX"
  ],
  "cities": [
    "Austin"
  ],
  "providerType": "any",
  "addressPurpose": "LOCATION",
  "primaryTaxonomyOnly": false,
  "autoSplit": true,
  "maxResults": 100
}
```

# Actor output Schema

## `providers` (type: `string`):

No description

# 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 = {
    "taxonomies": [
        "Dentist"
    ],
    "states": [
        "TX"
    ],
    "cities": [
        "Austin"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("openregistry/npi-healthcare-provider-search").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 = {
    "taxonomies": ["Dentist"],
    "states": ["TX"],
    "cities": ["Austin"],
}

# Run the Actor and wait for it to finish
run = client.actor("openregistry/npi-healthcare-provider-search").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 '{
  "taxonomies": [
    "Dentist"
  ],
  "states": [
    "TX"
  ],
  "cities": [
    "Austin"
  ]
}' |
apify call openregistry/npi-healthcare-provider-search --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,openregistry/npi-healthcare-provider-search"
        }
    }
}
```

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/E4tFJHNxKbEbawwyM/builds/0ARBB62IGxav3gQ0t/openapi.json
