Open Government, Taiwan API

Free to Use Varies (check documentation)

Overview

Taiwan Government Open Data API (data.gov.tw) offers access to thousands of datasets from Taiwanese government agencies, including economic, environmental, and social statistics. The API is free and requires no authentication for most datasets, making it easy to start exploring. It supports search and direct dataset download, with many datasets available in JSON format.

💡

Beginner Tip

Datasets are identified by a numeric ID visible in the URL on data.gov.tw — use that ID in the API request to retrieve data directly in JSON or CSV format.

Available Data

Use case: Integrate taiwan government open data data into web and mobile applications
Open Government, Taiwan data via REST API
JSON-formatted response data
Freely accessible without authentication

Example Response

JSON Response
{
  "status": "success",
  "data": {
    "result": "Data from Open Government, Taiwan",
    "description": "Taiwan Government Open Data",
    "timestamp": "2025-01-15T10:00:00Z"
  }
}

Field Reference

success Whether the request was processed successfully
result.records Array of data rows from the requested dataset
result.total Total number of rows available in this dataset
result.fields Column definitions including field name and data type
result.resource_id The unique identifier of the dataset resource that was queried

Implementation Example

const url = "https://data.gov.tw/";
const response = await fetch(url);
if (!response.ok) throw new Error(`Request failed: ${response.status}`);
const data = await response.json();
console.log(data);

What Can You Build?

Note: These code examples are AI-generated and unverified. Always refer to the official API documentation for accurate usage.

Common Errors & Troubleshooting

Response text contains garbled Traditional Chinese characters Dataset metadata is in Traditional Chinese and was decoded incorrectly
Force UTF-8 decoding in your client; if still garbled, try Big5 as a fallback for older datasets
Dataset API returns HTML instead of JSON Some older datasets on the portal do not have a machine-readable API endpoint
Check the dataset page for an API tab; if absent, use the direct file download link (CSV/JSON/XML) listed on the page
404 on dataset resource URL Government agencies occasionally move or remove dataset files
Re-check the dataset page on data.gov.tw for updated resource links; the dataset may have been updated with a new URL

Matrix Score Breakdown

🌐 Reachability 30/30
⚡ Speed 5/20
🔒 Security 15/15
🛠 Developer XP 15/20
✓ Reliability 7/15
Response Time 1953ms

Fully tested on Apr 5, 2026

Technical Specifications

Auth No Auth
HTTPS REQUIRED
CORS UNKNOWN
Category Government
Difficulty Beginner
Verified: 2026-04-04

Similar APIs

View All →