OpenAQ Air Quality Scraper
Pricing
$1.00 / 1,000 results
OpenAQ Air Quality Scraper
Scrapes real-time air quality measurements from OpenAQ by coordinates with a radius or by country code. Returns each measurement as a flat row with pollutant, value, station, and timestamp.
Pricing
$1.00 / 1,000 results
Rating
0.0
(0)
Developer
ParseForge
Maintained by CommunityActor stats
0
Bookmarked
2
Total users
1
Monthly active users
9 days ago
Last modified
Categories
Share
OpenAQ Air Quality Scraper
Scrape real-time air quality measurements from OpenAQ by coordinates or country, up to a million per run. Every row includes pollutant values, station location, and timestamp. No login required. Export to CSV, JSON, Excel, or XML.
OpenAQ aggregates air quality data from thousands of monitoring stations worldwide, but querying it manually means paging through API responses and normalizing fields. This Actor reads the public OpenAQ API directly, filters by pollutant, and returns each measurement as a flat row. You can target a city with coordinates and a radius, or pull every station in a country.
| Who uses it | What they scrape OpenAQ for |
|---|---|
| Environmental researchers | Comparing pollution levels across cities for a study |
| Health analysts | Tracking PM2.5 exposure near hospitals or schools |
| Urban planners | Identifying neighborhoods with poor air quality |
| Data journalists | Building air quality maps for a story |
| App developers | Feeding real-time AQI into a weather or health app |
What it does
This Actor collects air quality measurements from OpenAQ by coordinates with a radius or by country code, and returns each measurement as a flat row.
- ๐ Coordinate search: give a latitude, longitude, and radius up to 25 km to get nearby stations.
- ๐ Country-wide pull: use a two-letter ISO code to collect measurements from every station in that country.
- ๐งช Pollutant filter: restrict results to PM2.5, PM10, O3, NO2, SO2, CO, NO, NOx, or black carbon.
- ๐ Bring your own key: a shared OpenAQ key is included, but you can supply your own for higher rate limits.
Results export to CSV, JSON, Excel, or XML, or straight from the API.
What you can do with OpenAQ data
๐ Track pollution trends.
A researcher pulls weekly PM2.5 measurements for 20 cities and plots the trend to see which areas are improving.
๐ฅ Map health risks.
A public health analyst collects NO2 values near schools and flags locations above the WHO guideline.
๐ฐ Power a news story.
A journalist scrapes O3 levels across a metro area and builds an interactive map showing the worst neighborhoods.
๐ฑ Feed a consumer app.
A developer runs the Actor hourly for a user's coordinates and shows the current AQI on the home screen.
Why choose this scraper
| What you get | |
|---|---|
| No API setup | A shared OpenAQ key is preconfigured, so the first run works immediately. |
| Flat, clean rows | Every measurement comes back with pollutant, value, station, and timestamp in one schema. |
| Scale to a million rows | Set maxItems up to 1,000,000 and let the Actor page through the API for you. |
| Export anywhere | Download as CSV, JSON, Excel, or XML, or push to a dataset you already use. |
How it compares
This Actor and the Openaq Air Quality Scraper both pull air quality data, but this one reads directly from OpenAQ while the competitor uses the World Air Quality Index API.
| Feature | ParseForge | Openaq Air Quality Scraper |
|---|---|---|
| Data source | OpenAQ API | World Air Quality Index API |
| Pollutant filter | Yes | Not listed |
| Coordinate search with radius | Yes | Not listed |
| Country-wide pull | Yes | Not listed |
| Max measurements per run | 1,000,000 | Not listed |
| Free API key included | Yes | Yes |
Configure the run
Drive the Actor from coordinates with a radius or a country code, and the pollutant filter runs as each measurement is read so only matching rows reach your dataset. The Input tab lists every parameter.
A first run with the defaults:
{"coordinates": "34.0522,-118.2437","radiusKm": 12,"maxItems": 10}
A larger pull:
{"coordinates": "34.0522,-118.2437","radiusKm": 12,"maxItems": 200}
Pricing
Pay-per-result: $0.001 per result collected. You pay only for the results written to your dataset.
| Results collected | Approximate cost |
|---|---|
| 100 results | $0.10 |
| 1,000 results | $1.00 |
| 10,000 results | $10.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
- Create a free Apify account with $5 in credit.
- Open the OpenAQ Air Quality Scraper.
- Set your inputs and any filters, then click Start.
- 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 OpenAQ 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/openaq-air-quality-scraper"
Then prompt it in plain language to run the scraper and read back the results.
Troubleshooting
Why am I getting no results?
Make sure the coordinates are in "latitude,longitude" order with a comma and no spaces. Increase the radius, or try a country code instead. Some regions have very few stations.
Why did the run stop before reaching maxItems?
The Actor stops when there are no more matching stations. If you filtered by pollutant, try removing the filter or choosing a more common pollutant like PM2.5.
I got an authentication error.
The shared key may be rate-limited. Get your own free OpenAQ key and paste it into the apiKey field, then rerun.
The coordinates field is ignored.
Coordinates take priority over country code. If both are set, the Actor uses coordinates. Clear the coordinates field to use the country code.
Can I get data for multiple cities in one run?
Not directly. Run the Actor once per city with different coordinates, or use a country code to get all stations in that country and filter the results afterward.
FAQ
| Question | Answer |
|---|---|
| Do I need an OpenAQ API key? | No. A shared key is included by default. For heavy or commercial use, get your own free key at explore.openaq.org and paste it into the apiKey field. |
| How do I get measurements for a specific city? | Use the coordinates field with the city's latitude and longitude, and set a radius in kilometers. The Actor returns all stations within that radius. |
| Can I filter by pollutant? | Yes. Choose from PM2.5, PM10, O3, NO2, SO2, CO, NO, NOx, or black carbon in the parameter dropdown. Leave it on Any to get all pollutants. |
| What is the maximum number of measurements I can collect? | You can set maxItems up to 1,000,000 per run. The Actor pages through the OpenAQ API until it reaches that number or runs out of matching stations. |
| How fresh is the data? | The Actor queries the OpenAQ API in real time, so you get the latest measurements available from each station. |
| Can I get historical data? | This Actor returns current measurements. OpenAQ does offer historical data through its API, but this Actor is designed for real-time pulls. |
| What does a row look like? | Each row is a flat object with fields like pollutant, value, unit, station name, latitude, longitude, and timestamp. The exact fields are shown in the sample output. |
| Can I run this on a schedule? | Yes. Use Apify's scheduler to run the Actor hourly, daily, or weekly and keep a rolling dataset of air quality. |
| Is there a limit on the radius? | The radius can be set from 1 to 25 kilometers. For larger areas, use the country code to pull all stations in a country. |
| What if I get no results? | Check that your coordinates are in the correct "latitude,longitude" format and that the radius is at least 1 km. Some countries have sparse station coverage. |
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 OpenAQ. 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.
