PHPackages                             coredevelopment/craft-meteo - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [API Development](/categories/api)
4. /
5. coredevelopment/craft-meteo

ActiveCraft-plugin[API Development](/categories/api)

coredevelopment/craft-meteo
===========================

A headless weather plugin for Craft CMS using the Open-Meteo API.

5.0.4(10mo ago)09MITPHPPHP &gt;=8.2

Since Jul 12Pushed 10mo agoCompare

[ Source](https://github.com/coredevel/craft-meteo)[ Packagist](https://packagist.org/packages/coredevelopment/craft-meteo)[ RSS](/packages/coredevelopment-craft-meteo/feed)WikiDiscussions main Synced 1mo ago

READMEChangelogDependencies (4)Versions (6)Used By (0)

craft-meteo
===========

[](#craft-meteo)

A headless weather plugin for Craft CMS using the Open-Meteo API.

---

Features
--------

[](#features)

- **Headless, frontend-agnostic**: No frontend output, just robust weather data for your templates or APIs.
- **Granular variable selection**: Choose which weather variables to fetch for each granularity (current, minutely\_15, hourly, daily).
- **Weather code to icon/description mapping**: Built-in mapping for Weather Icons CSS, including day/night logic.
- **Admin panel**: Configure API variables, location, units, and cache from a Craft CP section.
- **Twig variable**: Access weather data anywhere in your templates: `craft.meteo.weather()`
- **Cache management**: Weather data is cached for performance; clear cache from the admin panel.
- **Extensible**: Clean, service-based architecture for easy extension.

---

Requirements
------------

[](#requirements)

- Craft CMS 5.8.0+
- PHP 8.2+

---

Installation
------------

[](#installation)

**From the Plugin Store:**

- Go to the Plugin Store in your project’s Control Panel and search for “meteo”.
- Press “Install”.

**With Composer:**

```
composer require coredevelopment/craft-meteo
./craft plugin/install craft-meteo
```

---

Configuration &amp; Usage
-------------------------

[](#configuration--usage)

### Settings

[](#settings)

- **Location**: Set latitude, longitude, and timezone.
- **Units**: Choose temperature, windspeed, precipitation units, and time format.
- **Variables**: For each granularity (current, minutely\_15, hourly, daily), select which weather variables to fetch.
- **Cache Duration**: Set how long weather data is cached (in seconds).

All settings are managed in the Craft CP under the “Meteo Settings” section.

### Twig Usage

[](#twig-usage)

Fetch weather data anywhere in your templates:

```
{% set weather = craft.meteo.weather() %}
{{ dump(weather) }}
```

- You can pass `lat`, `lon`, or override any settings:

```
{% set weather = craft.meteo.weather(49.2, -2.1, { forecast_days: 2 }) %}
```

### Data Structure

[](#data-structure)

The returned array mirrors the Open-Meteo API, with additional `weather_code_meta` for icon/description mapping:

```
{
  "current": {
    "weather_code": 2,
    "is_day": 1,
    "weather_code_meta": {
      "description": "Partly cloudy",
      "icon": "wi wi-day-cloudy"
    },
    ...
  },
  "hourly": { ... },
  "daily": { ... }
}
```

- If `is_day` is present, icon will be day/night specific. If not, a generic icon is used.

### Weather Icons CSS Integration

[](#weather-icons-css-integration)

To display weather icons in your frontend, include the [Weather Icons CSS library](https://erikflowers.github.io/weather-icons/) in your HTML:

```

```

- See the [Weather Icons project](https://erikflowers.github.io/weather-icons/) for icon previews and documentation.
- The plugin provides the correct icon class in the `weather_code_meta.icon` property for each weather data point.

**Example usage in Twig:**

```

{{ weather.current.weather_code_meta.description }}
```

---

Admin Tools
-----------

[](#admin-tools)

- **Clear Cache**: Use the “Clear Cache” button in the Meteo admin panel to force-refresh weather data.
- **Settings Persistence**: All settings are stored per environment and persist across deployments.

---

Developer Notes
---------------

[](#developer-notes)

- **Extending**: Add new variables or mapping by editing `Settings.php` and `WeatherService.php`.
- **API**: All param-building logic is in `WeatherService::getWeather`. No logic in `fetchFromApi`.
- **Debugging**: Debug logs are written for variable selection and API param-building.

---

Credits &amp; Support
---------------------

[](#credits--support)

- **Core Development x iPop Digital Collaboration**
- Support:
- MIT License

---

Changelog
---------

[](#changelog)

See [CHANGELOG.md](CHANGELOG.md) for release notes.

###  Health Score

32

—

LowBetter than 71% of packages

Maintenance58

Moderate activity, may be stable

Popularity4

Limited adoption so far

Community6

Small or concentrated contributor base

Maturity52

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~0 days

Total

5

Last Release

301d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/cf2a7c9ec45658f0f3904865e5f6b5daccf2c5ca266652e41c40274067873901?d=identicon)[coredevel](/maintainers/coredevel)

---

Top Contributors

[![coredevel](https://avatars.githubusercontent.com/u/138916?v=4)](https://github.com/coredevel "coredevel (5 commits)")

---

Tags

pluginapiheadlesscraftcmsweatherforecastopen-meteoipopdigital

###  Code Quality

Static AnalysisPHPStan

Type Coverage Yes

### Embed Badge

![Health badge](/badges/coredevelopment-craft-meteo/health.svg)

```
[![Health](https://phpackages.com/badges/coredevelopment-craft-meteo/health.svg)](https://phpackages.com/packages/coredevelopment-craft-meteo)
```

###  Alternatives

[craftcms/element-api

Create a JSON API for your elements in Craft

503701.3k8](/packages/craftcms-element-api)[adinan-cenci/climatempo-api

Uma api para previsão de tempo escrita em PHP.

448.2k](/packages/adinan-cenci-climatempo-api)[rakibdevs/openweather-laravel-api

Laravel package to connect https://openweathermap.org/ to get customized weather data for any location on the globe immediately

7648.2k](/packages/rakibdevs-openweather-laravel-api)[rugaard/weatherkit

Integrate Apple WeatherKit API into your project

111.4k](/packages/rugaard-weatherkit)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
