Skip to content
Sophie

Public API for Swiss health insurance premiums

The same figures as the comparator, in JSON, without a key and without an account. Official FOPH data, free reuse with attribution.

GET/api/v1/lieux

Resolves a postcode or municipality name to its premium region. The mandatory entry point: a premium belongs to the (canton, premium region) pair, and that join ships with no tariff file.

Parameters

ParameterRequiredDescription
qyesa 4-digit postcode (1800) or the start of a municipality name (Vev)

Try it

curl "https://comparaison-des-primes-lamal.ch/api/v1/lieux?q=1800"

Response

{
  "requete": "1800",
  "trouves": 1,
  "lieux": [
    {
      "no_ofs": 5890,
      "commune": "Vevey",
      "npa": 1800,
      "canton": "VD",
      "region_de_prime": 1
    }
  ]
}

GET/api/v1/primes

Every basic-cover premium available at an address, sorted by ascending price, with each offer’s annual excess over the cheapest.

Parameters

ParameterRequiredDescription
lieuyesa 4-digit postcode or a municipality name
agenointeger 0–120 — sets the age class and the allowed deductibles (default: 35)
franchisenoan official tier for that class (default: the lowest)
accidentno1 to include accident cover, 0 to suspend it (default: 1)
languenode, fr, it or en — the language of model names (default: fr)

Try it

curl "https://comparaison-des-primes-lamal.ch/api/v1/primes?lieu=1800&age=35&franchise=300"

Response

{
  "annee": 2026,
  "source": "Office fédéral de la santé publique (OFSP), opendata.swiss",
  "donnees_du": "2026-08-24",
  "licence": "CC BY 4.0 — réutilisation libre avec mention de la source",
  "fournies_par": "https://comparaison-des-primes-lamal.ch",
  "documentation": "https://comparaison-des-primes-lamal.ch/fr/api/",
  "demande": {
    "lieu": "Vevey",
    "npa": 1800,
    "canton": "VD",
    "region_de_prime": 1,
    "age": 35,
    "classe_d_age": "ADULTE",
    "franchise": 300,
    "accident_inclus": true,
    "annee": 2026
  },
  "resultats": 105,
  "offres": [
    {
      "no_ofsp": 312,
      "caisse": "Atupri Assurance de la santé SA",
      "modele": "HMO",
      "prime_mensuelle": 570.1,
      "prime_annuelle": 6841.2,
      "surcout_annuel": 0
    },
    {
      "no_ofsp": 1509,
      "caisse": "Sanitas Grundversicherungen AG",
      "modele": "TelMed (Compact One)",
      "prime_mensuelle": 571,
      "prime_annuelle": 6852,
      "surcout_annuel": 10.8
    },
    "… 103 autres"
  ]
}

GET/api/v1/caisses

The 34 authorised insurers, each with the number of regions where it is cheapest, its median rank and its median annual excess. That figure is published nowhere else.

Try it

curl "https://comparaison-des-primes-lamal.ch/api/v1/caisses"

Response

{
  "annee": 2026,
  "source": "Office fédéral de la santé publique (OFSP), opendata.swiss",
  "donnees_du": "2026-08-24",
  "licence": "CC BY 4.0 — réutilisation libre avec mention de la source",
  "fournies_par": "https://comparaison-des-primes-lamal.ch",
  "documentation": "https://comparaison-des-primes-lamal.ch/fr/api/",
  "total": 34,
  "caisses": [
    {
      "no_ofsp": 8,
      "nom": "CSS Assurance-maladie SA",
      "nom_court": "CSS",
      "positionnement": {
        "zones_actives": 42,
        "zones_total": 42,
        "zones_ou_la_moins_chere": 0,
        "rang_median": 11,
        "surcout_annuel_median": 602.4
      }
    },
    "… 33 autres"
  ]
}

GET/api/v1/observatoire

The aggregates: premium gap between regions of the same canton, and the eleven-year rise canton by canton.

Try it

curl "https://comparaison-des-primes-lamal.ch/api/v1/observatoire"

Response

{
  "annee": 2026,
  "source": "Office fédéral de la santé publique (OFSP), opendata.swiss",
  "donnees_du": "2026-08-24",
  "licence": "CC BY 4.0 — réutilisation libre avec mention de la source",
  "fournies_par": "https://comparaison-des-primes-lamal.ch",
  "documentation": "https://comparaison-des-primes-lamal.ch/fr/api/",
  "national": {
    "zones_tarifaires": 42,
    "caisses": 34,
    "prime_la_plus_basse": 385.8,
    "ecart_annuel_max_dans_un_canton": 1400.4,
    "canton_de_cet_ecart": "ZH",
    "hausse_mediane_par_canton_pourcent": 65.4,
    "periode": "2015-2026"
  },
  "ecarts_intercommunaux": [
    "…"
  ],
  "hausses_par_canton": [
    "…"
  ]
}

What you can rely on

Provenance travels with the figures

Every response carries `source`, `annee`, `licence` and the calculation profile. Data that travels without its source ends up attributed to someone else, or disputed with no way to defend itself.

Errors say what to fix

An unknown deductible does not return "invalid parameter" but the list of tiers allowed for that age class. You should not have to open this page twice.

No personal data goes in

No name, no exact address, no email: a postcode, an age and a deductible are enough to compute a premium. The API therefore has nothing to protect and nothing to log.

No in-house ranking

Sorting is by ascending price, the first row is the cheapest. There is no "best offer" field: that would be an opinion dressed as data.

Technical details

  • CORS open to all origins. No cookies, no sessions.
  • Responses cached for one hour client-side, one day server-side.
  • No announced rate limit, therefore no guarantee: for sustained use, cache the response on your side.
  • The data changes once a year, when the FOPH publishes the following year’s premiums.