Card_mod colors not showing on android

Since about 2 weeks I have noticed that some logic I use within a dashboard card is not working on the android companion app where it does work within a browser.

I have an entities card with the following logic

card_mod:
style:
hui-generic-entity-row $: |
.text-content:not(.info) {
color:
{% if (states(‘sensor.stock_change_today’)[:1]) == ‘-’ %}
red
{% else %}
green
{% endif %}
}

This is working perfectly fine on desktop browser but no longer on android app. Has something changed recently that broke this logic somehow.

Right now my phone shows the app was updated 2 days ago and when I check the version it shows 2025.11.1-full (18678). The issue has been there for longer than 2 days though. From memory I did update the app somewhere like 1-2 weeks ago but not in the last 2 days so not sure why it says that.

Does anybody know whether something has changed within the android app that could have caused this as card_mod has not been updated for quite some time.

A few thoughts

  • card_mod 3.4.6 fixes an issue with styling entity rows directly. However as you say its working on desktop, then you are likely on 3.4.6 or targetting the entities card.
  • Your description has signs of either caching issue and/or duplicate card_mod running. If you are using Frontend module URL, check out the latest v4 instructions (also applicable to v3) and make sure that your Dashboard resource URL and Frontend module URL match EXACTLY. If you change your Frontend module URL you will need to restart HA. Once all done, refresh cache in Companion App through debug options.

Yes for some reason the color is back this morning so I think indeed it was some caching issue.

Thanks for giving me this information as I wasn’t aware of the cache refresh via debug options.

1 Like