Because Volcanoes Don’t Sleep: CO₂ Monitoring with Home Assistant (La Palma)

Hi all,

I’m sharing this write-up for what is probably a very small subset of the Home Assistant community: people using Home Assistant who are living on or staying near Cumbre Vieja on La Palma (Canary Islands).

After the 2021 volcanic eruption, carbon dioxide (CO₂) has become a long-term risk in parts of the island, most notably in Puerto Naos. CO₂ is heavier than air and can accumulate in low-lying or poorly ventilated areas when volcanic gases continue to seep up through the ground. This means levels can rise indoors without any obvious warning signs (no smell, no smoke).

As a result, around 1,300 CO₂ sensors have been deployed in the area. They are placed both outdoors (along streets, every few meters) and indoors (homes, apartments, shops).

The apartment we rented for a holiday stay had one of these indoor sensors installed:

We were honestly not aware that CO₂ was a potential risk at this destination. The Airbnb host downplayed it (“think of it like a smoke detector, just a precaution”), but my partner was understandably uneasy. So I decided to turn it into a small holiday Home Assistant project. It turned out to be much easier than I expected.

Each indoor sensor has a QR code that links to a very simple public webpage showing:

  • CO₂ concentration
  • humidity
  • temperature
  • relative pressure

Screenshot of the webpage (I can’t share the link due to privacy):

So all I had to do was scrape that page and turn it into a Home Assistant sensor.

Example (URL partially anonymized for privacy):

- platform: rest
  name: "CO2 Puerto Naos"
  unique_id: co2_puerto_naos
  resource: "https://red.alerta-co2.org/_A6BXXXXX"
  scan_interval: 60
  timeout: 15
  headers:
    User-Agent: "HomeAssistant"
  value_template: >
    {% set t = value | regex_findall_index(
      'Dióxido de carbono</td>\\s*<td>\\s*([0-9]+),([0-9]+)\\s*PPM', 0
    ) %}
    {{ (t[0] ~ '.' ~ t[1]) | float }}
  unit_of_measurement: "ppm"
  device_class: carbon_dioxide
  state_class: measurement

Humidity, temperature, pressure, battery level, etc. can be extracted in exactly the same way.

Once the sensor was in HA, everything else was trivial:

  • simple automations for threshold-based notifications
  • graphs showing the daily evolution
  • reassurance during the night (there was some concern it might spike while sleeping—it didn’t)

The biggest benefit was psychological: instead of repeatedly walking over to the physical sensor to “check again”, my partner could rely on notifications and trends. That alone reduced stress significantly.

If I were living there long-term, I’d probably ask neighbors if they’re willing to share their sensor URLs and build aggregated views or averages. This isn’t a “1200 ppm, open a window” scenario—it’s more a 40,000 ppm, drop everything and evacuate the area kind of risk. Early detection and alerting really matter.

For anyone interested in the broader context of these sensors and why Puerto Naos is so heavily monitored, this BBC piece gives a good overview:

Hopefully this helps someone else in a similar situation—or at least shows how flexible Home Assistant can be, even on holiday.

By the way: I can only recommend La Palma as a holiday destination. The weather is great, the nature is really beautifull, the people are kind and the vulcano is sleeping (for now).

1 Like