Weather Summary Icon Status


I have the following weather information trigger:

- platform: forecast
  api_key: 123456789
    - summary

Somehow, it only shows on the GUI an “eye” as icon and the “status” in clear text. I would like to change the icon depending to the status. Has anyone an idea how to do this? Would be nice to have those symbols used from material design.

We have an open story for this. A weather component could translate the textual summaries into standardized output and the frontend show icons according the state.

I was going to ask this very question, you beat me to it!

I noticed one of the variables was…

- platform: forecast
  api_key: ##############
    - icon

but instead of displaying an icon it just outputs the name of the material design icon for the current conditions e.g.


I was also wondering if it is possible to get an actual forecast for the weather instead of the current conditions. I’d like to set up notifications / automations based on the forecast for the next week for example, but none of the listed variables appear to be anything other than current conditions.

1 Like

Was answered here

Only the OWM supports forecasts.

Thanks for this.

Is there any way that a variable could be called within the customise.yaml…

  icon: mdi:{get current state: sensor.weather_icon}

worked for me by setting up the group :wink:

icon: ‘{{ “mdi:”+states(“sensor.weather_icon”) | d(“mdi:weather-rainy”) }}’

Your template method doesn’t appear to work for me, can you provide a more detailed example config?

What I noticed is that there are sufficient mdi icons related to weather on made by Austin Andrews.

Why is it that I cannot add them?

Will show a symbol for the current weather:

platform: yr

The OWM component docs state that the data is only available in Metric at the present time; is this still true?

Yes, it’s still only metric.

I’m loading icon from the sensor Forecast.IO and weather forecast from OWM as I noticed the OWM icons don’t match the MDI names.

  • platform: forecast
    scan_interval: 900
    friendly_name: forecastio
    api_key: [redacted]
    units: auto
    • icon

Do you mean the other way around maybe? I noticed the Forcast IO icon names don’t match the HASS used mdi icons.

f.i. (clear-day), hass (weather-sunny)

1 Like

Came up with this after some reading up. Possible for the component?

incoming_icons_value = {

elif self.type == 'icon':
	for icon in incoming_icons_value:
		if icon.split(';') .......

…lost after this since not skilled enoughto do this myself…yet.

Got the forcast values and put them next to the ones I found in the mdi.html


I didn’t pay close attention to it and that’s why I set a default icon (to avoid getting errors), but thanks for the mapping, probably easy to do with simple {% if %} {% elif %} {% endif %} in my template… Am working now on grouping my automations and creating scripts to allow delay based on input sliders, but I’ll sure come back to your findings and post the results (if you don’t beat me to it :wink: )

1 Like

Okay. Good looking out.

Tried this: icon: > {% set weatherIcons = {"clear-day":"weather-sunny", "clear-night":"weather-night", "partly-cloudy-day":"weather-partlycloudy", "partly-cloudy-night":"weather-cloudy","cloudy":"weather-cloudy","rain":"weather-pouring","sleet":"weather-hail","snow":"weather-snowy","wind":"weather-windy","fog":"weather-fog"} %} {{"mdi:"+weatherIcons[states("sensor.weather_icon")]|d("mdi:weather-partlycloudy")}}

But the icon doesn’t seem to ever be set…

Did you try without the “>”?

Yeah, talked with devs, templating the icon is not currently possible. I’m going to look into implementing it and pushing it up if I can.

1 Like

I wonder if instead of templating the icon you could try setting the entity_picture:?

Use one of the png weather icon sets that are available - some of which are already named appropriately - and then just did a substitution on the image name.