DEV Community

Fast Data
Fast Data

Posted on

Do countries that shop online also run their firms on AI? I checked 27 EU countries (Eurostat 2025)

I pulled two fresh Eurostat datasets for a short-video series and noticed they look suspiciously alike:

  • AI in firms: share of enterprises with 10+ employees (excluding the financial sector) that use at least one AI technology, 2025 (isoc_eb_ai).
  • Online shopping: share of people who bought something online in the last 12 months, 2025 (isoc_ec_ib20, indicator I_BLT12).

Across the 27 EU countries, the two correlate with r = 0.70 (Spearman rank correlation also 0.70). Countries where almost everyone shops online tend to be the countries whose companies use AI.

AI use in firms vs online shopping, 27 EU countries, Eurostat 2025

The numbers

Country Firms using AI People shopping online
Denmark 42.0% 91.2%
Finland 37.8% 82.0%
Sweden 35.0% 88.8%
Belgium 34.5% 78.5%
Netherlands* 33.2% 94.2%
Germany 26.0% 81.4%
EU average 20.0% 73.6%
Ireland 19.6% 95.1%
Czechia 17.6% 83.7%
Italy 16.4% 56.2%
Poland 8.4% 69.7%
Romania 5.2% 60.3%

*Eurostat flags the Netherlands' 2025 AI value as a break in series. Dropping it changes r from 0.70 to 0.68.

Three things that stood out

1. The Nordic block sits near the top on both. Denmark, Finland and Sweden are in the top right corner. Denmark's 42.0% means more than two in five firms use some AI technology, roughly double the EU average of 20.0%.

2. Ireland is the big outlier. 95.1% of people bought online in 2025, the highest share in the EU, but only 19.6% of firms use AI, just below the EU average. Without Ireland the correlation rises from 0.70 to 0.77. My guess (and it is only a guess): Irish consumers buy heavily from platforms based abroad, while the AI question is asked of firms located in Ireland. The two indicators measure different populations, and Ireland makes that visible.

3. Germany is middle of the pack on AI, above average on shopping. 26.0% of German firms use AI (about one in four) and 81.4% of people shop online. Both are above the EU average, but well behind the Nordics.

What this does not show

  • Correlation, not causation. A third factor (income, digital skills, broadband, company size structure) likely drives both. I did not control for anything.
  • "Uses AI" is a yes/no question. A firm that uses one chatbot counts the same as one that runs its whole planning on machine learning.
  • No trend claims. I only compare 2025. The list of AI technologies in the survey can change between years, so year-over-year jumps need care.

Getting Eurostat data into Python without pain

Eurostat's API returns JSON-stat: values come as a flat, sparse dictionary keyed by a single index, and you have to unfold that index into the dimensions yourself. This is the helper I used (standard library only):

import json, urllib.parse, urllib.request

API = "https://ec.europa.eu/eurostat/api/dissemination/statistics/1.0/data/"

def eurostat_rows(dataset, **filters):
    url = API + dataset + "?" + urllib.parse.urlencode({"format": "JSON", "lang": "EN", **filters})
    with urllib.request.urlopen(url, timeout=60) as resp:
        d = json.load(resp)
    ids, sizes = d["id"], d["size"]
    codes = {k: {i: c for c, i in d["dimension"][k]["category"]["index"].items()} for k in ids}
    rows = []
    for key, value in d["value"].items():
        k, row = int(key), {}
        for dim, size in reversed(list(zip(ids, sizes))):  # last dimension changes fastest
            row[dim] = codes[dim][k % size]
            k //= size
        row["value"], row["flag"] = value, d.get("status", {}).get(key)
        rows.append(row)
    return rows

ai = eurostat_rows("isoc_eb_ai", indic_is="E_AI_TANY", size_emp="GE10",
                   unit="PC_ENT", nace_r2="C10-S951_X_K", sinceTimePeriod="2025")
shop = eurostat_rows("isoc_ec_ib20", indic_is="I_BLT12", ind_type="IND_TOTAL",
                     unit="PC_IND", sinceTimePeriod="2025")
Enter fullscreen mode Exit fullscreen mode

Two gotchas cost me time:

Gotcha Symptom Fix
A wrong filter code the response has a dimension of size 0 and no values, no error check d["dimension"][dim]["category"]["label"]; for firm size it is GE10, not the label text
Ignoring status you silently compare provisional or broken series keep the flag column (p provisional, e estimated, b break in series) and decide per row

The full helper is in our public repo: snippets/eurostat_table.py.

Try it

Disclosure: I build data tools for AI agents as Fast Data on Apify; this article uses only Eurostat's free API and needs none of them. If you work with European business data, our open data-recipes repo has the snippet above plus n8n workflows and Agent Skills for public tenders, supplier checks and e-invoices.

Question: what would you control for first to see if the AI/online-shopping link survives: income per head, broadband coverage, or the share of large companies? And does anyone have a better explanation for Ireland?

Top comments (0)