ParseForge Scrapers

Data.gov Dataset Scraper

parseforge/data-gov-scraper

AutomationDeveloper toolsOther

Scrapes Data.gov catalog search results by keyword or URL. Returns each dataset as a flat row with title, description, publisher, formats, and metadata. Export to CSV, JSON, Excel, or XML.

Run this scraper See the API call
Total users
21
Monthly active
0
Total runs
303
Bookmarked
0
Rating
Not rated yet
Last modified
12 days ago

Overview

ParseForge

Data.gov Dataset Scraper

Scrape the Data.gov catalog by any search term, up to a million datasets per run. Every dataset comes with its title, description, publisher, formats, and metadata. No API key. Export to CSV, JSON, Excel, or XML.

Data.gov is the U.S. government's open data portal, but browsing it by hand means clicking through thousands of pages. This Actor reads the public catalog search directly, so you can pull every dataset that matches a keyword, sorted by relevance, popularity, or date, into one flat table.

Who uses it What they scrape Data.gov for
Data journalists Find federal datasets on a beat, like climate or health, without manual browsing.
Researchers Build a corpus of government datasets for a systematic review or meta-analysis.
Open data advocates Monitor what new datasets a topic area publishes each week.
Data engineers Feed a pipeline with fresh catalog metadata for a data discovery tool.

What it does

This Actor collects Data.gov dataset records by search query or catalog URL, and returns each dataset as one flat row with its metadata.

  • ๐Ÿ”Ž Search by keyword: type any term, like "air quality" or "medicare", and get every matching dataset.
  • ๐Ÿ”— Start from a URL: paste a Data.gov search URL and the Actor extracts the query for you.
  • ๐Ÿ“Š Sort your results: order by relevance, popularity, last published date, or date added.
  • ๐Ÿ“ฆ Cap the output: set a maximum from 1 to 1,000,000 datasets per run.

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

What you can do with Data.gov data

๐Ÿ“ฐ Build a federal data beat.

A journalist searches "climate change" and exports the latest datasets to spot new sources for a story.

๐Ÿงช Assemble a research corpus.

A researcher pulls every dataset matching "air quality" to list available measurements for a meta-analysis.

๐Ÿ“ˆ Monitor open data releases.

An open data advocate runs the Actor weekly with a topic query to track newly published datasets.

๐Ÿ”ง Feed a data catalog.

A data engineer scrapes the full catalog for a keyword and loads the rows into an internal discovery tool.

Why choose this scraper

What you get
No API key Reads the public catalog search, so you start scraping in one click.
Flat rows Each dataset is one row, ready for CSV, JSON, Excel, or XML export.
Full metadata Title, description, publisher, formats, and more come with every record.
Scale Collect up to a million datasets in a single run.

How it compares

No other Store actor targets Data.gov the same way, so the honest comparison is with the alternatives teams actually weigh.

Data.gov Dataset Scraper Build it in-house By hand
Setup Run it now, zero config Days of engineering None, but hours per pull
When Data.gov changes Maintained for you You fix it You re-learn the page
Proxies, retries, anti-bot Built in Your problem Browser only
Output Fixed JSON schema, CSV/Excel export Whatever you build Copy-paste
Cost Pay per result Engineering time Analyst hours

Configure the run

Drive the Actor from a search term or a Data.gov search URL, and set a sort order and a maximum number of datasets to collect. The Input tab lists every parameter.

A first run with the defaults:

{
  "searchQuery": "climate change",
  "maxItems": 25
}

A larger pull:

{
  "searchQuery": "climate change",
  "maxItems": 200
}

Pricing

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

Results collected Approximate cost
100 results $6.75
1,000 results $67.50
10,000 results $675.00

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 to collect up to 1,000,000 results per run.

Run it

  1. Create a free Apify account with $5 in credit.
  2. Open the Data.gov Dataset Scraper.
  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 (run-sync-get-dataset-items) or the ApifyClient for JavaScript and Python.

Use with AI agents (MCP)

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

claude mcp add --transport http apify "https://mcp.apify.com?tools=parseforge/data-gov-scraper"

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

Troubleshooting

Why am I getting no results?

Check your search term. Try a broader keyword or remove special characters. Also verify that the startUrl, if used, contains a valid q parameter.

The run stops before reaching my maxItems.

The catalog may have fewer matching datasets than your maximum. Try a more general search term or lower the sort to relevance.

Some fields are empty in the output.

Not every dataset on Data.gov has all metadata fields. Empty values mean the catalog did not provide that field for that record.

The run takes a long time.

Large maxItems values mean more requests. Reduce the maximum or narrow your search term to speed up the run.

I get an error when using a startUrl.

Make sure the URL is a Data.gov search URL with a q parameter, like https://catalog.data.gov/dataset?q=water. Other URLs are not supported.

FAQ

Question Answer
Do I need a Data.gov API key? No. This Actor reads the public catalog search pages directly, so there is no registration or key required.
What does each row in the output contain? Each row is one dataset with its title, description, publisher, formats, and other metadata fields from the catalog.
Can I scrape all datasets on Data.gov? Yes, if you set a high maximum and use a broad search term, the Actor can collect up to one million datasets per run.
How do I sort the results? Use the sort input to order by relevance, popularity, last published date, or date added.
Can I start from a Data.gov search URL instead of a keyword? Yes, paste a URL like https://catalog.data.gov/dataset?q=water into the startUrl field and the Actor will use its query.
What export formats are supported? You can export the results to CSV, JSON, Excel, or XML from the Apify dataset.
Is this Actor affiliated with Data.gov? No, this is an independent scraper built on the public catalog. It is not operated by the U.S. General Services Administration.
How often is the data updated? The Actor reads the live catalog on each run, so you get the current metadata as of the run time.
Can I filter by dataset format, like CSV or GeoJSON? The Actor returns all matching datasets with their format list. You can filter the output afterward by the formats field.
What is the maximum number of datasets I can collect? You can set maxItems up to 1,000,000 datasets per run.

Related actors

Browse the full ParseForge collection 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. General Services Administration. 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.

Input

FieldTypeWhat it doesDefault
searchQuery string Keyword(s) to search the Data.gov catalog, e.g. "climate change", "air quality", "medicare". climate change
sort string (4 options) How to order results. relevance
startUrl string Optional. A Data.gov search URL (e.g. https://catalog.data.gov/dataset?q=water). Its "q" is used as the search query. not set
maxItems integer How many datasets to collect per run. 25

Pricing

from $5.50 per 1,000 results

Charged forWhat it isPrice each
Actor Start Charged when the Actor starts running. Number of events charged depends on Actor memory (one event per GB, minimum one event). $0.045 to $0.0675
result Single result in the default dataset. $0.0055 to $0.00825

Tiered: the lower figure is the price on a higher Apify plan. Billing and the free credit live on Apify.

API

One POST returns the dataset directly. Same shape for every scraper in the library, so swapping the slug is the only change.

POST ยท run and get results
curl -X POST "https://api.apify.com/v2/acts/parseforge~data-gov-scraper/run-sync-get-dataset-items?token=$APIFY_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "helloWorld": 123
  }'

Examples

Input that runs as-is.

input.json
{
  "helloWorld": 123
}

Reviews

No reviews yet. Be the first.

Issues

We build and maintain this scraper, so a problem with it comes to us. Report it on the Apify listing and the thread stays attached to the scraper where the next person can find it: open an issue.

Broken and urgent, or you would rather not post in public? Write to parseforge@protonmail.com and it reaches the people who wrote it.

Related scrapers

Run Data.gov Dataset Scraper on Apify All scrapers