MQTT NodeRed values

If the topic “text” contains only numbers, you can create a numeric variable from the text variable [message received from]

Example to “Convert” a textvar which holds only numbers, to a numvar:

.
If numvar changes, set color to the value stored in [numvar]:

Probably this app is interesting to you