Input number with lower values

I have build my own energy management system and want to make input numbers for the energy costs so that I don’t need to edit the template every time it changes.

Now the lowest value can be 0.0001. my energy company charges me 0.21127 euro per kWh

So at the moment I can’t use helpers for these values. Please change helpers to being able to set lower values

Not sure if this helps in the meantime, but I have the same problem in UK. I just used p/kWh instead for the input_number

You could use cents / kWh, ie 21.127 for the input_number and use a template sensor to multiply it by 0.01 for use in the energy dashboard

Stupid of me but you can also just use an input_text and in the template do a float on the text to make it a number. Then you can go as low as you want

Are you sure about that?

Maybe only for slider type input numbers?

For example, I’m using this:

t93_peak_energy_cost:
  name: T93 Peak Energy Cost
  mode: box
  min: 0.00000001
  max: 100.00000001
  unit_of_measurement: "$/kWh"
  icon: mdi:currency-usd

It displays fine in the front end and my template calculations work as they should.

Screenshot 2021-09-02 at 23-34-50 Overview - Home Assistant

There is one caveat though. The more info pop-up is not correct.

Untitled

I thought I had an issue open for this but I can’t find it.

I just tried your suggestion and the red line seems to indicate an error and the tooltip is wrong ?

I assume without step: it is defaulting to step: 1 ?

If I add step: 0.001 error goes away, but need step: 0.00001

Well that tool tip is wrong too. They’re your max and min yeah?

Which means it can be anywhere in between those values, which your number is.

The good news is that it does not generate an error in the front end or the logs and the input_number works as expected in templates.

I think we need to open a new issue.

They were set to min: 0.00001 and max: 100.00001

The input text works but doesn’t display a unit (as expected)

Are you going to open a new issue ?

I’ll do it tomorrow. Far too late here. :sleeping:

OK thanks.

Its more like when trying to set up the helper in the UI that you get an error and can’t save it. Haven’t tried it adding it directly in a yaml