How to Choose an LED Resistor (Series LEDs Too)

By Anatolie · Updated 2026-11-21

An LED needs a resistor in series because, unlike a bulb, it doesn't limit its own current. Once the voltage across it passes its forward voltage, the current rises steeply with only a small increase in voltage, and without something to cap it the LED (or the pin driving it) burns out. The resistor's job is to set that current.

The formula

R = (Vsupply − Vf) ÷ If

Vsupply is the supply voltage, Vf is the LED's forward voltage, and If is the current you want, in amps. The resistor drops whatever voltage the LED doesn't, and Ohm's law turns that leftover voltage and the target current into a resistance.

Worked example

A red LED (Vf ≈ 2.0 V) on a 5 V supply at 20 mA:

R = (5 − 2.0) ÷ 0.020 = 150 Ω. The resistor dissipates 3.0 V × 0.020 A = 0.06 W, so an ordinary 1/8 W or 1/4 W part is plenty.

The LED resistor calculator does this, rounds up to the next standard E12 value, and suggests a power rating.

Typical forward voltages and currents

LED colourTypical Vf
Red, orange, yellow1.8–2.2 V
Yellow-green (older type)about 2.1 V
Bright green, blue, white2.8–3.4 V

These are typical figures; the datasheet for your exact part is better. Standard 3 mm and 5 mm indicator LEDs are usually rated around 20 mA continuous, but modern ones are often bright enough at 5–10 mA, which also lightens the load on whatever drives them.

Round the resistor up, not down

The calculated value rarely matches a resistor you can buy. Pick the next standard value above it: a slightly larger resistor means slightly less current, which is safe, while a smaller one pushes the LED past the current you chose.

Leave voltage headroom

A white LED (Vf ≈ 3.0 V) on a 3.3 V supply at 15 mA gives R = 0.3 ÷ 0.015 = 20 Ω. That works on paper, but forward voltage varies from part to part and with temperature: if Vf is really 3.1 V, the current drops by a third. With only a few tenths of a volt across the resistor, the brightness is at the mercy of the LED. Aim for at least about 1 V across the resistor, or use a constant-current driver when the supply is close to Vf.

Several LEDs in series

For a string of N identical LEDs, subtract every forward voltage:

R = (Vsupply − N × Vf) ÷ If

Three white LEDs (3.1 V each) on 12 V at 20 mA: R = (12 − 9.3) ÷ 0.020 = 135 Ω. The next E12 value up is 150 Ω, which gives (12 − 9.3) ÷ 150 = 18 mA and dissipates about 0.05 W. If N × Vf reaches the supply voltage, the string won't light at all — split it into shorter strings.

Don't share one resistor between parallel LEDs

Wiring several LEDs in parallel behind a single resistor looks economical, but no two LEDs have exactly the same forward voltage. The one with the lowest Vf takes most of the current, runs hotter, drops its Vf further, and takes even more. Give each LED, or each series string, its own resistor.

Driving LEDs from a microcontroller

An Arduino Uno pin can source or sink 40 mA at its absolute maximum, and the usual practice is to stay at or below 20 mA per pin — and to watch the total across all pins. For more current than that, switch the LED with a transistor. To check what wattage the resistor needs in other circuits, see how to size a resistor's wattage; to identify the resistor in your hand, the resistor color code calculator.