Sensor values modify for new entity

Hi,
I have simple questions about at dashboard function

  • I want to add a offset (+5) to a temperature sensor
  • I want the Sum of to sensors in a new entity ( Grid + Solar ) Power

I cant find a howto for these basic functions.
Hope somebody could help
thx

Hi.
You can do both with a template sensor.

Something like this. Test your expression in developer tools / templates

{{ states(‘sensor.my_temperature’) | int(0) + 5 }}
{{ states(‘sensor.grid_power’) | float(0) + states(‘sensor.solar_power’) | float(0)}}