You could try this. I’ve had no problem storing numbers in node red long term. I’ve found context storage to survive reboots and even several version up dates. You need to first enable context storage in settings.js
This is a modified counter that has been very stable. I am also not a coder so maybe run this along side the ha helper.
You can set the date by entering yyyy-mm-dd. It will convert it to a timestamp and store it. Set the inject to a time for it to check everyday. If the timestamp for today is >= the stored value it will send on otherwise off.
[{"id":"6aac76c5.ad1b88","type":"inject","z":"d6a46901.ebee1","name":"","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"2022-04-16","payloadType":"str","x":310,"y":780,"wires":[["9fa0724c.c50e68"]]},{"id":"9fa0724c.c50e68","type":"function","z":"d6a46901.ebee1","name":"Convert to timestamp","func":"p = msg.payload;\nmsg.payload= Date.parse(p);\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":560,"y":780,"wires":[["1376ad87.877e72"]]},{"id":"1376ad87.877e72","type":"change","z":"d6a46901.ebee1","name":"set timestamp","rules":[{"t":"set","p":"topic","pt":"msg","to":"set","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":800,"y":820,"wires":[["d70f06ec.63d5d8"]]},{"id":"d70f06ec.63d5d8","type":"function","z":"d6a46901.ebee1","name":"date checker","func":"var date_time = context.get(\"future_date\"); //change \"future_date\" for each instance\n\nif(msg.topic == \"set\") {\n date_time = msg.payload;\n} else if (msg.payload >= date_time) {\n date_time_now = \"on\";\n} else {\n date_time_now = \"off\";\n}\ncontext.set(\"future_date\", date_time); //change \"future_date\" for each instance\nnode.status({ text: date_time_now });\n\nmsg.date_time_now = date_time_now; \nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":955,"y":860,"wires":[["5a6122b9.1598fc"]],"icon":"node-red-dashboard/ui_dropdown.png","l":false},{"id":"cdfb7286.5abc48","type":"inject","z":"d6a46901.ebee1","name":"Set daily check time","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"","payloadType":"date","x":330,"y":860,"wires":[["d70f06ec.63d5d8"]]},{"id":"5a6122b9.1598fc","type":"debug","z":"d6a46901.ebee1","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"date_time_now","targetType":"msg","statusVal":"","statusType":"auto","x":1140,"y":860,"wires":[]}]
https://nodered.org/docs/user-guide/context#saving-context-data-to-the-file-system