US Census Bureau Data API Scraper
Pricing
from $1.60 / 1,000 census row returneds
US Census Bureau Data API Scraper
Query official US Census Bureau Data API datasets such as ACS and the Decennial Census by year, variables and geography. Returns structured rows with variable values, geography identifiers, the query URL and retrieval time.
Pricing
from $1.60 / 1,000 census row returneds
Rating
0.0
(0)
Developer
Muhammad Afzal
Maintained by CommunityActor stats
0
Bookmarked
2
Total users
1
Monthly active users
16 days ago
Last modified
Categories
Features
Share
US Census Bureau Data Scraper
Query US Census Bureau American Community Survey (ACS) and Decennial Census tables by year, variable codes and geography, and get one structured dataset item per geography row. It costs $2.001 per 1,000 rows on the FREE tier ($1.60 on GOLD) and is built for analysts, researchers, public-sector teams, geospatial workflows and AI agents that need Census variables by state, county, tract, place, ZIP code (ZCTA) or district.
No API key is needed. Rows come from the public Census tables at data.census.gov, which publish the same variable codes (B01001_001E, S0101_C01_001E, DP05_0001E, P1_001N) as the Census Data API.
What it returns
Each item contains:
| Field | Description |
|---|---|
dataset | Census dataset path, such as acs/acs5. |
year | Census vintage year. |
values | Requested variable codes mapped to their string or null values, followed by the geography columns. |
geography | Geography identifiers in Census Data API column names, such as state, county, tract or zip code tabulation area, plus the full ucgid. |
queryUrl | The Census table request that produced the row. |
retrievedAt | UTC retrieval timestamp. |
Values stay strings because Census publishes tabular data as text, and a variable code can be a count, percentage, margin of error or annotation. Use the dataset's variable metadata to interpret units and margins of error.
Which datasets and geographies work?
Datasets: acs/acs1, acs/acs5, acs/acs1/subject, acs/acs5/subject, acs/acs1/profile, acs/acs5/profile, acs/acsse, dec/pl, dec/dhc, dec/dp and dec/sf1 (2010), for any vintage year Census publishes them.
Geographies (for): us, region, division, state, county, county subdivision, tract, block group, place, congressional district, metropolitan statistical area/micropolitan statistical area, public use microdata area, zip code tabulation area and school district (unified). Use * for all, or one or more comma-separated codes.
Not covered: time-series datasets, Population Estimates, the Economic Census and PUMS microdata. Choose dataset and variable codes from the official Census documentation first; this Actor does not guess what a code means.
Inputs
{"dataset": "acs/acs5","year": 2023,"variables": ["NAME", "B01001_001E"],"for": "county:*","in": ["state:06"],"maxResults": 100}
This returns 2023 ACS 5-year rows for every county in California with each county name and total-population estimate. The prefilled default query returns all 52 state-level rows (50 states, DC and Puerto Rico).
List parent geographies in in, one per entry and in order, with specific codes. For example, tracts in Los Angeles County use "for": "tract:*" with "in": ["state:06", "county:037"].
To select geographies by Census GEO_ID, use ucgid instead of for/in. It takes one ID, a comma-separated list, or a parent-child form such as 0400000US06$0500000 (all counties in California):
{"dataset": "acs/acs5","year": 2023,"variables": ["NAME", "B01001_001E"],"ucgid": "0400000US24"}
predicates keep only the rows whose value matches exactly. The key must also be in variables:
{"variables": ["NAME", "B01001_001E"],"for": "county:*","in": ["state:06"],"predicates": { "NAME": "Los Angeles County, California" }}
Variables can come from up to 10 tables in one run; rows from different tables are joined on the geography.
Output and limits
The run summary is stored in the OUTPUT key-value record. It includes the rows available, rows returned, every Census request URL, the number of requests made, warnings, and whether maxResults or the Apify charge limit stopped output. Census has no generic page cursor. If the result is capped, narrow the geography or predicates for the next query.
Each run makes one Census request per table and geography selection, with at most 50 geography selections and 100 requests. A query for every ZIP code or every tract in a large state downloads a large table and can take a minute or more.
Valid queries with no rows complete successfully with status EMPTY, an empty dataset and a truthful summary. Invalid input or a variable, table or year that Census does not publish (INVALID_INPUT), and Census request failures with no rows (FAILED), end the run as FAILED, with details in OUTPUT. A failure after some rows were saved keeps those rows (PARTIAL). Error objects are never mixed into the dataset.
Pricing
Pay per event. Prices by Apify plan tier:
| Event | FREE | BRONZE | SILVER | GOLD and above |
|---|---|---|---|---|
census-row-returned (one row saved to the dataset) | $0.002001 | $0.00195 | $0.0019 | $0.0016 |
apify-actor-start (per run, per started GB of memory) | $0.006251 | $0.006094 | $0.005938 | $0.005 |
The default memory is 256 MB, so a run is charged one start event. The default 52-row state query costs about $0.11 on the FREE tier. A row is saved before it is charged, the run stops before saving a row it cannot bill, and failed runs charge no row events.
Data source and compliance
The source is the US Census Bureau's public data at data.census.gov, the same tables documented for the Census Data API. Review the selected dataset's official documentation for coverage, vintage, variable definitions, margins of error, suppression and geographic limits. This Actor does not bypass access controls or collect private information.
FAQ
Do I need a Census API key? No. The Actor reads the public Census tables, and the input has no key field.
Why are values strings? Census publishes all table values as text. Convert them using the dataset's variable metadata.
How do I get more than one capped slice? Census has no page cursor. Narrow the geography or add predicates and run again.
Why did my run end with INVALID_INPUT? The dataset, geography or variable code is not supported, or Census does not publish that table for the chosen year. The OUTPUT warning names the problem.
Last verified: 2026-11-01