Voltage divider circuit getting hot
Voltage dividers work great if and only if all of the current that flows through R1 also flows through R2.







simulate this circuit &ndash; Schematic created using CircuitLab

However, as soon as another current path forms between the resistors, the divider no longer works. Since some of the current is diverted away from R2, the voltage drop changes. What's worse, if the current to the load is variable, the voltage of the divider will be variable too:







simulate this circuit

It's for this reason that resistor dividers are almost never used as a power source. Instead, you would use a voltage regulator of some type. Voltage regulators have active feedback to maintain the output voltage regardless of current draw (up to a point, of course). And some regulators, such as SMPS, can have very high efficiencies, so you don't have to burn off so much heat to drop the voltage.

For your simple circuit, a linear regulator is probably best suited. They're very simple to use (typically a single IC chip plus two capacitors) and inexpensive. They're great for most low-current digital applications. The 7805 is a very common linear regulator that outputs a fixed 5V, however, it is ancient technology and there are plenty of modern devices available as well.







simulate this circuit