Home & workshop Electronics

LED resistor calculator

Supply voltage
V
LED forward voltage
V
Red ~1.8–2.1, blue/white ~3.0–3.4
Desired current
mA
Number of LEDs
Wiring
Resistor needed 150 Ω
(supply − Vf) ÷ current
Nearest E24 value 150 Ω
Power in the resistor 0.06 W
Minimum resistor rating 0.12 W
Voltage across the resistor 3 V
Total current 20 mA
Viable? yes
R = (Vsupply − Vf) ÷ I

Two LEDs in parallel behind a single resistor do not share current evenly. Forward voltage varies between parts by a tenth of a volt or so, and because the current-voltage curve is exponential, the one with the slightly lower Vf takes most of the current, runs hotter, drops further, and takes more still. Give each LED its own resistor, or drive the string in series where the same current necessarily flows through all of them.

Advertisement
320 × 100

The resistor value is the supply voltage minus the LED forward voltage, divided by the desired current. A 2 V red LED at 20 mA on a 5 V supply needs (5 − 2) ÷ 0.02 = 150 Ω, dissipating 60 mW.

How to choose an LED resistor

1 Enter the supply voltage and the LED forward voltage from its datasheet.
2 Set the current — 20 mA is a typical indicator, less for modern high-efficiency parts.
3 Take the nearest standard value at or above the calculated one.
4 Check the resistor rating: aim for at least double the calculated dissipation.

Forward voltage is the number people guess and should not. It varies by colour because it follows the band gap of the semiconductor: red and yellow sit around 1.8 to 2.1 V, green nearer 2.2, and blue and white at 3.0 to 3.4. Using a red LED figure for a white one on a 3.3 V rail produces a negative headroom and an LED that barely lights. The tool flags that case explicitly rather than showing a nonsense resistor value. And rounding matters in one direction only — pick the resistor above the calculated value, because too much resistance dims an LED while too little destroys it.

Questions

For a 2 V red LED at 20 mA, 150 Ω. For a 3.2 V white LED at 20 mA, 90 Ω — so 100 Ω as the nearest standard part.

Advertisement
300 × 250
Was this tool any good?
INTERNAL SIGNAL ONLY · WE USE IT TO FIND TOOLS WORTH REBUILDING