Singapore data.gov.sg Datasets Scraper avatar

Singapore data.gov.sg Datasets Scraper

Pricing

from $7.50 / 1,000 results

Go to Apify Store
Singapore data.gov.sg Datasets Scraper

Singapore data.gov.sg Datasets Scraper

Scrapes records from any data.gov.sg datastore resource by resource ID or search term. Returns each record as a flat row for export to CSV, JSON, Excel, or XML.

Pricing

from $7.50 / 1,000 results

Rating

0.0

(0)

Developer

ParseForge

ParseForge

Maintained by Community

Actor stats

0

Bookmarked

2

Total users

1

Monthly active users

12 days ago

Last modified

Share

ParseForge

Singapore data.gov.sg Datasets Scraper

Scrape Singapore government open data from data.gov.sg by resource ID or search term, up to a million rows per run. Every record comes back as a flat row with the dataset's own fields. No API key, no proxy, no setup. Export to CSV, JSON, Excel, or XML.

Singapore's official open data portal, data.gov.sg, exposes thousands of public datasets through a datastore API, but querying it means writing code, handling pagination, and reshaping JSON. This Actor reads any datastore resource by its resource_id or a free-text search, and returns each record as one flat row in a fixed schema. It works for HDB resale prices, school directories, COE results, weather readings, and every other public dataset on the portal.

Who uses itWhat they scrape data.gov.sg for
Data analystsPull the latest Singapore government datasets into a spreadsheet for reporting.
ResearchersCollect historical records from a specific data.gov.sg resource for study.
JournalistsGather official statistics on housing, transport, or health for a story.
App developersFeed Singapore open data into an application or dashboard.
Policy analystsMonitor changes in government-published indicators over time.

What it does

This Actor collects records from a data.gov.sg datastore resource, identified by resource ID or search term, and returns each record as a flat row.

  • πŸ” Resource ID or search: point the Actor at a dataset by its datastore resource_id, or let a free-text query find matching records.
  • πŸ“„ Flat row output: every record is returned as one flat object, ready for CSV, JSON, Excel, or XML export.
  • βš™οΈ Built-in pagination: the Actor follows the datastore API's pagination automatically, so you get every matching record up to your maxItems limit.
  • πŸ”Ž Full-row search: the optional query parameter filters records on the server side, so only relevant rows are downloaded.
  • πŸ‡ΈπŸ‡¬ Official Singapore data: reads directly from data.gov.sg, the government's open data portal, with no third-party transformation.

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

What you can do with data.gov.sg data

🏠 Track HDB resale prices.

A property analyst runs the Actor on the HDB resale transactions resource to collect the latest flat prices by town and flat type, then charts price trends for a market report.

🏫 Build a school directory.

An education startup scrapes the MOE school information resource to get every school's name, address, and contact details, then loads the rows into their app's database.

πŸš— Monitor COE prices.

A car dealer runs the Actor daily on the COE bidding results resource to track certificate prices and adjust their vehicle pricing strategy.

🌦️ Collect weather readings.

A climate researcher pulls historical weather station data from the National Environment Agency's resource to study rainfall patterns over the past decade.

πŸ“Š Feed a dashboard.

A government contractor schedules the Actor to refresh multiple datasets every morning, then pushes the flat rows into a business intelligence tool for public reporting.

Why choose this scraper

What you get
No API keydata.gov.sg's datastore API is open, so you can start scraping without registration.
Any datasetWorks with every resource on the portal, from HDB resale prices to school directories.
Flat outputNested JSON is flattened into one row per record, ready for analysis.
Server-side filteringThe query parameter filters records before download, saving time and bandwidth.
ScalableCollect up to 1,000,000 records in a single run.

How it compares

This Actor is a direct scraper for any data.gov.sg datastore resource, while the competitors below offer either pre-built joins or focus on a single dataset.

FeatureParseForgeSingapore Open Data Studio - Gov Data JoinsSingapore School Directory (MOE SchoolFinder)Singapore HDB Resale Flat Prices Scraper
Scrape any data.gov.sg dataset by resource IDYesNot listedNot listedNot listed
Free-text search within a datasetYesNot listedNot listedNot listed
Cross-dataset joinsNot listedYesNot listedNot listed
MOE school directory dataYes, if you provide the school directory resource IDNot listedYesNot listed
HDB resale flat pricesYes, if you provide the HDB resale resource IDNot listedNot listedYes
CSV, JSON, Excel, XML exportYesYesNot listedNot listed

Configure the run

Drive the Actor with a datastore resource_id from any data.gov.sg dataset URL, and optionally narrow the results with a free-text query. The maxItems limit caps how many records are collected per run. The Input tab lists every parameter.

A first run with the defaults:

{
"datasetId": "d_8b84c4ee58e3cfc0ece0d773c8ca6abc",
"maxItems": 10
}

A larger pull:

{
"datasetId": "d_8b84c4ee58e3cfc0ece0d773c8ca6abc",
"maxItems": 200
}

Pricing

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

Results collectedApproximate cost
100 results$0.85
1,000 results$8.50
10,000 results$85.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 Singapore data.gov.sg Datasets 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.sg 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/mygov-singapore-data-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 the resource_id is correct and that the dataset is accessible through the datastore API. If you used a query, try removing it to see if the dataset returns any records at all.

Why did the run stop before reaching maxItems?

The dataset may have fewer records than your maxItems limit. The Actor stops when the API returns no more pages. Lower maxItems if you want a smaller sample.

Why are some fields missing from my output?

The datastore API may omit fields that are empty for a particular record. Check the dataset's schema on data.gov.sg to see which fields are defined.

Why did I get an error about an invalid resource_id?

Make sure you copied the full resource_id, including any hyphens or underscores. It is case-sensitive. Test the resource_id in the data.gov.sg API explorer first.

Why is the run taking a long time?

Large datasets with many records can take time to paginate through. Reduce maxItems or add a query to filter the data server-side.

FAQ

QuestionAnswer
What is a resource_id and where do I find it?A resource_id is the unique identifier for a datastore resource on data.gov.sg. Open any dataset page on data.gov.sg, click the API link, and copy the resource_id from the URL or the API documentation.
Can I scrape any dataset on data.gov.sg?Yes, as long as the dataset is exposed through the datastore API. Most tabular datasets on the portal are available this way. Paste the resource_id into the Actor input and it will collect the records.
How does the query parameter work?The query parameter is a free-text search that filters records on the server side. It matches against all fields in the dataset, so you can use it to find rows containing a specific value, like a town name or a school name.
What is the maximum number of records I can collect?You can set maxItems up to 1,000,000 records per run. The Actor will follow the API's pagination until it reaches that limit or the dataset is exhausted.
Do I need an API key or proxy?No. data.gov.sg's datastore API is open and does not require authentication. The Actor runs on Apify's infrastructure, so you do not need to manage proxies.
What output formats are supported?The Actor returns data as JSON by default. You can export the results to CSV, JSON, Excel, or XML from the Apify platform.
Can I schedule this Actor to run regularly?Yes, you can set up a schedule in Apify to run the Actor daily, weekly, or at any interval. This is useful for keeping a copy of frequently updated datasets.
Does this Actor handle pagination automatically?Yes, the Actor follows the datastore API's pagination links automatically, so you do not need to write any pagination logic.
What if the dataset has nested fields?The Actor flattens nested JSON objects into a single flat row, so each record becomes one line in your output file.
Is this an official Government Technology Agency product?No, this Actor is built and maintained by a third party. It reads public data from data.gov.sg but is not affiliated with GovTech.

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 Government Technology Agency (GovTech). 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.