Statistics Sweden (SCB) Scraper avatar

Statistics Sweden (SCB) Scraper

Pricing

from $26.33 / 1,000 results

Go to Apify Store
Statistics Sweden (SCB) Scraper

Statistics Sweden (SCB) Scraper

Scrape any dataset from Statistics Sweden via the SCB open data API. Population, employment, GDP, prices, exports, education, regional data. No API key required.

Pricing

from $26.33 / 1,000 results

Rating

0.0

(0)

Developer

ParseForge

ParseForge

Maintained by Community

Actor stats

0

Bookmarked

2

Total users

1

Monthly active users

19 hours ago

Last modified

Share

ParseForge Banner

🇸🇪 Statistics Sweden (SCB) Scraper

🚀 Export any official Swedish statistic in seconds. Browse the SCB tree, inspect a table's variables, or query the actual data points (population, GDP, employment, prices, trade, education, regional). No API key, no registration, no manual CSV wrangling.

🕒 Last updated: 2026-05-13 · 📊 3 modes, JSON-stat decoded · 🇸🇪 Full SCB catalog · 🌐 EN + SV labels

The Statistics Sweden (SCB) Scraper wraps the official SCB open data API (api.scb.se/OV0104/v1/doris) and turns the JSON-stat response into flat rows. The underlying dataset is published by Statistics Sweden (Statistiska centralbyrån), the Swedish government agency that has compiled national statistics since 1858.

The catalog covers every subject area SCB tracks. Population, labour market, national accounts, prices and consumption, trade, education, agriculture, environment, transport, public finance, living conditions, and regional breakdowns down to municipality level. This Actor returns table metadata, variable lists, or fully expanded data points with one dimension combination per row, ready to download as CSV, Excel, JSON, or XML.

🎯 Target Audience💡 Primary Use Cases
Economists, journalists, GIS analysts, demographers, fintech and proptech teams, academic researchers, public-sector planners, data engineersPopulation pyramids, regional dashboards, inflation tracking, labour-market reports, ESG benchmarks, OSM enrichment, longitudinal studies

📋 What the Statistics Sweden Scraper does

Three operating modes in a single Actor:

  • 🌳 Browse mode. Walks the SCB tree starting from any node. Empty path returns the 20+ top-level subject areas (BE for population, AM for labour, NR for national accounts, PR for prices). Drill down a level at a time to discover tables.
  • 📑 Table mode. Returns one row per dimension of a single table. Each row lists the variable code, label, value count, and a sample of valid codes plus their localized labels. Use this to figure out which filter codes to send before pulling the data.
  • 📊 Data mode. POSTs a JSON-stat query against a table endpoint and decodes the multi-dimensional response into flat rows. One row per dimension combination, with the numeric value, every dimension code, every localized label, the unit (persons, SEK, percent, etc.), and the source URL.

Output language switches between English and Swedish on a single input field. The Actor automatically caps unfiltered dimension queries so SCB does not reject them as too large.

💡 Why it matters: Sweden publishes one of the deepest open national-statistics catalogs in Europe, but the raw JSON-stat format is hostile to spreadsheets. This Actor decodes the cube into flat rows you can drop into BI tools, dashboards, or training datasets without writing a parser.


🎬 Full Demo

🚧 Coming soon: a 3-minute walkthrough showing how to browse the SCB tree, pick a table, and export real data points.


⚙️ Input

InputTypeDefaultBehavior
modeenum"browse"browse lists tree nodes, table returns variable metadata, data returns actual values.
pathstring""Tree path for browse mode. Empty = root. Examples: BE, BE/BE0101, AM, NR.
tableIdstring"BE/BE0101/BE0101A/BefolkningNy"Full table path. Required in table and data modes.
dataFiltersobject{}Dimension code -> list of values to include. Example: {"Region":["00"], "Alder":["tot"], "Kon":["1","2"]}.
languageenum"en"Response language for table titles and value labels. en or sv.
maxItemsinteger10Records to return. Free plan caps at 10, paid plan at 1,000,000.

Example: browse the Population subject area.

{
"mode": "browse",
"path": "BE",
"language": "en",
"maxItems": 50
}

Example: pull Swedish population by sex and age for 2024.

{
"mode": "data",
"tableId": "BE/BE0101/BE0101A/BefolkningNy",
"dataFilters": {
"Region": ["00"],
"Civilstand": ["OG"],
"Kon": ["1", "2"],
"Tid": ["2024"]
},
"language": "en",
"maxItems": 100
}

⚠️ Good to Know: SCB rejects queries that produce too many cells (HTTP 403/400). The Actor caps unfiltered non-time dimensions to a small sample and the time dimension to the latest period unless you set explicit values in dataFilters. Always preview a table with mode: "table" first to discover the dimension codes.


📊 Output

Each mode returns a different row shape. Download the dataset as CSV, Excel, JSON, or XML.

🧾 Schema for data mode

FieldTypeExample
🆔 tableIdstring"BE/BE0101/BE0101A/BefolkningNy"
📛 titlestring"Population by region, marital status, age, sex, observations and year"
🔢 valuenumber | null50937
🧭 dimensionsobject{"Region": "00", "Kon": "1", "Tid": "2024"}
🏷️ dimensionLabelsobject{"Region": "Sweden", "Kon": "men", "Tid": "2024"}
📐 unitstring | null"number of persons"
🔗 urlstring"https://api.scb.se/OV0104/v1/doris/en/ssd/BE/BE0101/BE0101A/BefolkningNy"
🕒 scrapedAtISO 8601"2026-05-12T23:44:23.667Z"

🧾 Schema for browse mode

FieldTypeExample
🆔 idstring"BE0101"
🏷️ typestring"l" (level) or "t" (table)
📛 textstring"Population statistics"
🔗 urlstring"https://api.scb.se/OV0104/v1/doris/en/ssd/BE/BE0101"
🕒 scrapedAtISO 8601"2026-05-12T23:44:23.667Z"

🧾 Schema for table mode

FieldTypeExample
🆔 tableIdstring"BE/BE0101/BE0101A/BefolkningNy"
📛 titlestring"Population by region, marital status, age, sex, observations and year"
🔡 variableCodestring"Region"
🏷️ variableTextstring"region"
🔢 valueCountinteger312
📋 sampleValuesstring[]["00", "01", "0114", "0115", "0117"]
📋 sampleValueTextsstring[]["Sweden", "Stockholm county", "Upplands Vasby", "..."]
🔗 urlstring"https://api.scb.se/OV0104/v1/doris/en/ssd/BE/BE0101/BE0101A/BefolkningNy"
🕒 scrapedAtISO 8601"2026-05-12T23:44:23.667Z"

📦 Sample record (data mode)


✨ Why choose this Actor

Capability
🌳Tree-walking browser. Discover the entire SCB catalog from the root, one node at a time.
📑Table introspection. Get every dimension, code, and label of any table before you query data.
📊JSON-stat decoder. Multi-dimensional cube becomes flat rows automatically.
🌐Bilingual. Switch between English and Swedish labels on a single input.
🛡️Safe defaults. Unfiltered queries auto-cap so SCB does not reject them as too large.
Fast. 10 data points in under 3 seconds, 10,000 records in under a minute.
🚫No authentication. SCB publishes the data under an open license. No key needed.

📊 Sweden's open statistics catalog underpins half of the Nordic data-journalism industry. The SCB API is the source, this Actor turns it into rows.


📈 How it compares to alternatives

ApproachCostCoverageRefreshFiltersSetup
⭐ Statistics Sweden Scraper (this Actor)$5 free credit, then pay-per-useFull SCB catalogLive per runTree path, table id, per-dimension filters, language⚡ 2 min
Manual CSV downloads from scb.seFreeSingle tables at a timeOn demandUI checkboxes🐢 Slow, no automation
Roll-your-own JSON-stat parserFreeFullLiveCustom🛠️ Hours of engineering
Third-party Nordic data vendors$$ subscriptionsCurated subsetVendor cadenceVendor-specific⏳ Days

Pick this Actor when you want a programmable interface to the official SCB API with the cube already decoded.


🚀 How to use

  1. 📝 Sign up. Create a free account with $5 credit (takes 2 minutes).
  2. 🌐 Open the Actor. Go to the Statistics Sweden (SCB) Scraper page on the Apify Store.
  3. 🌳 Browse first. Set mode: "browse" with an empty path to see all subject areas. Drill down until you find a table.
  4. 📑 Inspect the table. Switch to mode: "table" and set tableId to the full path. Read the variable codes.
  5. 📊 Query data. Switch to mode: "data", set dataFilters to scope the slice, click Start.
  6. 📥 Download. Grab your results in the Dataset tab as CSV, Excel, JSON, or XML.

⏱️ Total time from signup to downloaded dataset: 3-5 minutes. No coding required.


💼 Business use cases

📈 Economic Research & Finance

  • Track Swedish CPI, PPI, and HICP for inflation reports
  • Pull quarterly GDP for forecasting models
  • Wage and household-income trends for compensation studies
  • Labour-market series for currency and rates desks

🏘️ Proptech & Demographics

  • Population by municipality for site-selection models
  • Age-sex pyramids for product-market sizing
  • Migration flows for rental-market forecasting
  • Education attainment for talent-density maps

📰 Data Journalism

  • Reproducible tables sourced direct from SCB
  • Time-series for charts in long-form articles
  • Cross-municipality comparisons for investigative pieces
  • Live refresh on publication date for newsroom dashboards

🏛️ Public Sector & Policy

  • Regional planning datasets with one-click refresh
  • Public-health denominators by age band
  • Trade and energy series for industrial policy briefings
  • Reproducible baselines for budget and grant reviews

🔌 Automating Statistics Sweden Scraper

Control the scraper programmatically for scheduled runs and pipeline integrations:

  • 🟢 Node.js. Install the apify-client NPM package.
  • 🐍 Python. Use the apify-client PyPI package.
  • 📚 See the Apify API documentation for full details.

The Apify Schedules feature lets you trigger this Actor on any cron interval. Hourly, daily, or weekly refreshes keep downstream databases in sync automatically.


🌟 Beyond business use cases

The same structured records support research, education, civic projects, and personal initiatives.

🎓 Research and academia

  • Longitudinal demographic and labour studies
  • Reproducible cited datasets for theses and papers
  • Open-data assignments for statistics coursework
  • Comparative Nordic policy research

🎨 Personal and creative

  • Side projects mapping Swedish municipalities
  • Data-viz portfolios with current census numbers
  • Travel and migration analyses for personal blogs
  • Bilingual content backed by official figures

🤝 Non-profit and civic

  • NGO reports on inequality and regional disparities
  • Civic transparency dashboards for municipalities
  • Public-interest journalism on inflation and wages
  • Health-org denominators for vaccination coverage

🧪 Experimentation

  • Train forecasting models on official series
  • Validate fintech product hypotheses with macro data
  • Prototype LLM agents that answer stats questions
  • Test BI dashboards with live SCB feeds

🤖 Ask an AI assistant about this scraper

Open a ready-to-send prompt about this ParseForge actor in the AI of your choice:


❓ Frequently Asked Questions

🧩 How does it work?

The Actor hits the official SCB JSON-stat API (api.scb.se/OV0104/v1/doris). In browse mode it lists tree nodes. In table mode it returns variable metadata. In data mode it POSTs a JSON-stat query and decodes the multi-dimensional response into flat rows, one per dimension combination.

🌳 How do I find a table?

Start in browse mode with an empty path to see the top-level subject areas (BE for population, AM for labour, NR for national accounts, PR for prices, etc.). Drill down a level at a time. The tree node id becomes the next path segment. Tables are nodes with type "t".

📐 What does the value mean?

The value is the numeric measurement for the specific combination of dimension codes in that row. The unit field tells you what the value represents (persons, SEK, percent, kilograms, etc.).

🇸🇪 Can I get Swedish labels?

Yes. Set language: "sv" for Swedish labels on titles, dimension labels, and value labels. The default is English.

🛡️ Why do I get a 403 error?

SCB rejects queries that produce too many cells (typically 50,000+). Use dataFilters to scope the slice. The Actor caps unfiltered non-time dimensions automatically, but very wide tables may still trip the limit.

⏰ Can I schedule regular runs?

Yes. Use Apify Schedules to run this Actor on any cron interval (hourly, daily, weekly) and keep a downstream database in sync.

SCB publishes statistics under an open license (CC BY 4.0 in most cases). Cite Statistics Sweden as the source. Review the specific table license before commercial redistribution.

💼 Can I use this data commercially?

Yes. Official Swedish statistics are public information and can be used in commercial products. You are responsible for proper attribution and complying with the SCB terms of use.

💳 Do I need a paid Apify plan to use this Actor?

No. The free Apify plan is enough for testing and small runs (10 records per run). A paid plan lifts the limit to 1,000,000 records.

🔁 What happens if a run fails?

Apify automatically retries transient errors. If a run still fails, you can inspect the log in the Runs tab, fix the input (often a dataFilters issue), and re-run.

🌍 Does it cover other Nordic countries?

This Actor covers Statistics Sweden. For wider EU and member-state coverage, see the Eurostat Statistics Scraper in the recommended actors below.

🆘 What if I need help?

Our support team is here to help. Contact us through the Apify platform or use the Tally form linked below.


🔌 Integrate with any app

Statistics Sweden Scraper connects to any cloud service via Apify integrations:

  • Make - Automate multi-step workflows
  • Zapier - Connect with 5,000+ apps
  • Slack - Get run notifications in your channels
  • Airbyte - Pipe statistics into your warehouse
  • GitHub - Trigger runs from commits and releases
  • Google Drive - Export datasets straight to Sheets

You can also use webhooks to trigger downstream actions when a run finishes. Push fresh SCB data into your product backend, or alert your team in Slack.


💡 Pro Tip: browse the complete ParseForge collection for more reference-data scrapers.


🆘 Need Help? Open our contact form to request a new scraper, propose a custom data project, or report an issue.


⚠️ Disclaimer: this Actor is an independent tool and is not affiliated with, endorsed by, or sponsored by Statistics Sweden (Statistiska centralbyrån) or the Swedish government. All trademarks mentioned are the property of their respective owners. Only publicly available open data from the official SCB API is collected.