# US Census Geocoder Scraper (`parseforge/uscensus-geocoder-scraper`) Actor

Scrapes the US Census Geocoder to geocode addresses or reverse geocode coordinates. Returns standardized address, lat/lng, and optional Census tract, block, and county IDs.

- **URL**: https://apify.com/parseforge/uscensus-geocoder-scraper.md
- **Developed by:** [ParseForge](https://apify.com/parseforge) (community)
- **Categories:** Developer tools, Automation
- **Stats:** 2 total users, 0 monthly users, 89.7% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $11.00 / 1,000 result items

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?

Actors are web data automations that power AI and operations. They run on the Apify platform to scrape websites, process data, connect APIs, and automate workflows.
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.

- **AI agents and MCP clients** — the [Apify MCP server](https://docs.apify.com/integrations/mcp.md) at `https://mcp.apify.com` (remote, streamable HTTP, OAuth on first use).
- **Agentic workflows and local Actor development** — [Agent Skills](https://apify.com/.well-known/agent-skills/index.json) with the [Apify CLI](https://docs.apify.com/cli/docs.md): `npm install -g apify-cli`, then `apify login`.
- **JavaScript/TypeScript projects** — the official [JS/TS client](https://docs.apify.com/api/client/js/docs.md): `npm install apify-client`.
- **Python projects** — the official [Python client](https://docs.apify.com/api/client/python/docs.md): `pip install apify-client`.
- **Any other language** — 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

[![ParseForge](https://raw.githubusercontent.com/ParseForge/apify-assets/main/banner.jpg)](https://apify.com/parseforge?fpr=vmoqkp)

### US Census Geocoder Scraper

**Geocode US street addresses or coordinates with the official Census Geocoder, no API key needed.** Get standardized addresses, lat/lng, and optional Census tract, block, and county IDs. Export to CSV, JSON, Excel, or XML.

The Census Bureau's official geocoder is free, but its API limits batch sizes and returns verbose JSON. This Actor sends your addresses or coordinates straight to the Census Geocoder and returns one clean row per match, with optional Census geography enrichment. No API key, no code, no rate-limit headaches.

| Who uses it | What they scrape US Census Geocoder for |
|---|---|
| Real estate analysts | Batch geocode property lists to map listings and analyze neighborhood demographics. |
| Data journalists | Turn addresses in public records into coordinates for mapping stories. |
| GIS specialists | Enrich point data with Census tract and block IDs for spatial analysis. |
| Market researchers | Geocode customer addresses to study regional patterns and trade areas. |
| Nonprofit program managers | Map service locations to Census geographies for funding reports. |

### What it does

This Actor geocodes US addresses to coordinates or reverse geocodes coordinates to addresses using the official Census Geocoder, and returns each match as a flat row with optional Census tract, block, and county IDs.

- 📍 **Address to coordinates:** forward geocode one-line US addresses like '1600 Pennsylvania Ave NW, Washington, DC 20500'.
- 🗺️ **Coordinates to address:** reverse geocode lat/lng pairs to the closest matching street address.
- 🏛️ **Census geography enrichment:** optionally return the surrounding census tract, block, and county polygon IDs for each match.
- 📦 **Batch up to 1,000,000 inputs per run:** the Actor handles the pagination and rate limits for you.
- 📄 **Flat, export-ready rows:** every match comes back as one row with standardized address, coordinates, and optional geography IDs.

Results export to CSV, JSON, Excel, or XML, or straight from the API.

### What you can do with US Census Geocoder data

**🏠 Map a real estate portfolio.**

A real estate analyst pastes 5,000 property addresses, runs the Actor, and gets coordinates plus Census tract IDs to join with demographic data for site selection.

**📊 Enrich survey responses with geography.**

A market researcher reverse geocodes respondent coordinates to Census blocks, then aggregates responses by tract for regional reporting.

**🗞️ Geocode public records for a story.**

A data journalist feeds addresses from court filings into the Actor and maps them to reveal geographic patterns in evictions.

**🧭 Build a store locator.**

A developer geocodes a chain's store addresses once, stores the lat/lng pairs, and uses them to power a nearest-store finder.

**🏛️ Prepare grant reports.**

A nonprofit program manager geocodes client addresses and attaches Census tracts to demonstrate service coverage in low-income areas.

### Why choose this scraper

| | What you get |
|---|---|
| **Official Census data** | Matches come straight from the U.S. Census Bureau's geocoder, the same source used for federal statistics. |
| **No API key or setup** | The Actor handles authentication and rate limits, so you paste your list and run. |
| **Batch geocoding at scale** | Geocode up to a million addresses or coordinates in a single run. |
| **Census geography built in** | Optionally attach tract, block, and county IDs to every match for demographic analysis. |
| **Clean, flat output** | Each result is one row with standardized address, lat/lng, and optional geography, ready for CSV, JSON, Excel, or XML. |

### How it compares

This Actor and the U.S. Census Geocoder both call the same official Census service, but this Actor adds batch processing, a flat output schema, and optional geography enrichment in one run.

| Feature | ParseForge | U.S. Census Geocoder |
|---|---|---|
| Batch geocoding up to 1,000,000 inputs | Yes | Not listed |
| Optional Census tract, block, and county IDs | Yes | Yes |
| Flat, export-ready rows (CSV, JSON, Excel, XML) | Yes | Not listed |
| No API key required | Yes | Not listed |
| Handles rate limits automatically | Yes | Not listed |

### Configure the run

Drive the Actor from a list of addresses or a list of lat/lng pairs, and optionally enrich each match with Census tract, block, and county IDs. The Input tab lists every parameter.

A first run with the defaults:

```json
{
 "maxItems": 10,
 "mode": "address",
 "addresses": [
 "1600 Pennsylvania Ave NW, Washington, DC 20500",
 "350 5th Ave, New York, NY 10118",
 "1 Apple Park Way, Cupertino, CA 95014"
 ],
 "coordinates": [
 {
 "lat": 38.8977,
 "lng": -77.0365
 },
 {
 "lat": 40.7484,
 "lng": -73.9857
 }
 ]
}
```

A larger pull:

```json
{
 "maxItems": 200,
 "mode": "address",
 "addresses": [
 "1600 Pennsylvania Ave NW, Washington, DC 20500",
 "350 5th Ave, New York, NY 10118",
 "1 Apple Park Way, Cupertino, CA 95014"
 ],
 "coordinates": [
 {
 "lat": 38.8977,
 "lng": -77.0365
 },
 {
 "lat": 40.7484,
 "lng": -73.9857
 }
 ]
}
```

### Pricing

Pay-per-result: **$0.01467 per result** collected. You pay only for the results written to your dataset.

| Results collected | Approximate cost |
|---|---|
| 100 results | $1.47 |
| 1,000 results | $14.67 |
| 10,000 results | $146.70 |

New Apify accounts start with $5 in free credit.

### Free users

Free-plan runs return up to 10 results as a preview. [Upgrade your Apify plan](https://console.apify.com/sign-up?fpr=vmoqkp) to collect up to 1,000,000 results per run.

### Run it

1. [Create a free Apify account with $5 in credit](https://console.apify.com/sign-up?fpr=vmoqkp).
2. Open the [US Census Geocoder Scraper](https://apify.com/parseforge/uscensus-geocoder-scraper?fpr=vmoqkp).
3. Set your inputs and any filters, then click **Start**.
4. Export the results as CSV, Excel, JSON, or XML from the **Dataset** tab.

Run it programmatically through the [Apify API](https://docs.apify.com/api/v2) (`run-sync-get-dataset-items`) or the [ApifyClient](https://docs.apify.com/api/client/js) for JavaScript and Python.

### Use with AI agents (MCP)

Give an AI agent live access to US Census Geocoder through the Model Context Protocol. Add the Actor to Claude, Cursor, or any MCP client:

```bash
claude mcp add --transport http apify "https://mcp.apify.com/?tools=parseforge/uscensus-geocoder-scraper"
```

Then prompt it in plain language to run the scraper and read back the results.

### Troubleshooting

**Why am I getting no results?**

Check that your addresses are in one-line US format, like '1600 Pennsylvania Ave NW, Washington, DC 20500'. If you are in coordinates mode, make sure each object has 'lat' and 'lng' keys. Also verify that maxItems is at least 1.

**Some addresses return 'No\_Match'.**

The Census Geocoder could not find a match. Try simplifying the address, removing apartment numbers, or checking for typos. You can also switch to coordinates mode if you have approximate lat/lng.

**The run is slow for a large list.**

The Census service has rate limits, so the Actor waits between requests. For very large lists, consider splitting them into multiple runs or increasing the timeout.

**I enabled 'Return Census Geographies' but don't see tract IDs.**

Census geography is only returned when the address matches to a specific location. If the match is approximate or the address is a PO box, geography may be missing. Check the match type in the output.

**The output has more rows than my input.**

The Census Geocoder can return multiple candidate matches for one input. The Actor returns all candidates up to maxItems. If you want only the best match, filter the output by match type or score.

### FAQ

| Question | Answer |
|---|---|
| Is this the official US Census Geocoder? | Yes. The Actor calls the U.S. Census Bureau's public geocoding service, the same one used for federal statistics. It returns the same matches and geography IDs. |
| Do I need an API key? | No. The Census Geocoder is free and does not require registration. The Actor handles the requests for you. |
| How many addresses can I geocode in one run? | You can set the maximum results up to 1,000,000. The Actor processes your list in batches and respects the Census service's rate limits. |
| What is the difference between address and coordinates mode? | Address mode takes one-line US addresses like '350 5th Ave, New York, NY 10118' and returns lat/lng. Coordinates mode takes lat/lng pairs and returns the closest matching address. |
| What Census geographies can I get back? | When you enable 'Return Census Geographies', each match includes the census tract, block, and county polygon IDs. These are the same IDs used in Census data tables. |
| What format is the output? | The Actor returns a flat dataset. You can export it as CSV, JSON, Excel, or XML from the Apify platform. |
| Does it work for PO boxes or rural addresses? | The Census Geocoder handles most US addresses, including PO boxes and rural routes, but match quality depends on the input. The Actor returns the match type and any warnings from the Census service. |
| Can I geocode addresses outside the US? | No. The Census Geocoder only covers US addresses and territories. For international geocoding, use a different geocoding Actor. |
| How accurate are the coordinates? | The Census Geocoder returns coordinates based on its address database. Accuracy varies by address quality, but it is the same data used for official Census mapping. |
| Can I run this on a schedule? | Yes. You can schedule the Actor to run daily, weekly, or on any cron schedule, for example to geocode new addresses as they arrive. |

### Related actors

Browse the full [ParseForge collection](https://apify.com/parseforge?fpr=vmoqkp) for more scrapers.

🆘 **Need help?** Email parseforge@protonmail.com with your run ID, your input, and what you expected.

⚠️ **Disclaimer.** This Actor is unofficial and is not affiliated with, endorsed by, or sponsored by U.S. Census Bureau. It collects only publicly available data. You are responsible for using the collected data in compliance with the source's terms of service and applicable data-protection laws, including GDPR, CCPA, and PIPL. Do not use it to collect personal data unlawfully.

# Actor input Schema

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

How many results to collect per run.

## `mode` (type: `string`):

address = forward geocode one-line addresses to lat/lng. coordinates = reverse geocode a lat/lng pair to the closest matching address.

## `addresses` (type: `array`):

List of US one-line addresses to geocode. Example: '1600 Pennsylvania Ave NW, Washington, DC 20500'. Used only when mode = address.

## `coordinates` (type: `array`):

List of {lat, lng} pairs to reverse geocode. Used only when mode = coordinates.

## `returnGeographies` (type: `boolean`):

If enabled, each match is enriched with the surrounding census tract, block, and county polygon IDs.

## Actor input object example

```json
{
  "maxItems": 10,
  "mode": "address",
  "addresses": [
    "1600 Pennsylvania Ave NW, Washington, DC 20500",
    "350 5th Ave, New York, NY 10118",
    "1 Apple Park Way, Cupertino, CA 95014"
  ],
  "coordinates": [
    {
      "lat": 38.8977,
      "lng": -77.0365
    },
    {
      "lat": 40.7484,
      "lng": -73.9857
    }
  ],
  "returnGeographies": false
}
```

# Actor output Schema

## `overview` (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 = {
    "maxItems": 10,
    "mode": "address",
    "addresses": [
        "1600 Pennsylvania Ave NW, Washington, DC 20500",
        "350 5th Ave, New York, NY 10118",
        "1 Apple Park Way, Cupertino, CA 95014"
    ],
    "coordinates": [
        {
            "lat": 38.8977,
            "lng": -77.0365
        },
        {
            "lat": 40.7484,
            "lng": -73.9857
        }
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("parseforge/uscensus-geocoder-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 = {
    "maxItems": 10,
    "mode": "address",
    "addresses": [
        "1600 Pennsylvania Ave NW, Washington, DC 20500",
        "350 5th Ave, New York, NY 10118",
        "1 Apple Park Way, Cupertino, CA 95014",
    ],
    "coordinates": [
        {
            "lat": 38.8977,
            "lng": -77.0365,
        },
        {
            "lat": 40.7484,
            "lng": -73.9857,
        },
    ],
}

# Run the Actor and wait for it to finish
run = client.actor("parseforge/uscensus-geocoder-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 '{
  "maxItems": 10,
  "mode": "address",
  "addresses": [
    "1600 Pennsylvania Ave NW, Washington, DC 20500",
    "350 5th Ave, New York, NY 10118",
    "1 Apple Park Way, Cupertino, CA 95014"
  ],
  "coordinates": [
    {
      "lat": 38.8977,
      "lng": -77.0365
    },
    {
      "lat": 40.7484,
      "lng": -73.9857
    }
  ]
}' |
apify call parseforge/uscensus-geocoder-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,parseforge/uscensus-geocoder-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/CbHTvlrkdFTcM9Acw/builds/AQsyMWDtAfaC94Oun/openapi.json
