LED series resistor:
from supply voltage and target current to a part you can buy
Pick the right series resistor in three steps, round to a real standard value, and check the power it must dissipate.
Calcylator Editorial Team
Updated · 5 min read
Why an LED cannot be connected directly
An LED is not a resistor. Once the voltage across it passes its forward voltage, the current climbs very steeply, and a small voltage change can mean a large current change. Connect one straight to a battery and it will either pass a harmful current or fail quickly.
A series resistor fixes this by taking the excess voltage. Whatever the supply provides above the LED's forward voltage appears across the resistor, and Ohm's law then sets the current. It is a simple and cheap way to hold the current at a safe, predictable value.
The behaviour is described by the diode characteristic. Below the forward voltage, almost no current flows and the LED stays dark. Just above it, the current may rise by a factor of ten for a rise of a few tenths of a volt. A resistor linearises this dangerous curve by making the current depend mainly on the resistance.
This is why LED modules sold for 12 V use often have a resistor or a small driver built in, while a bare LED never does.
The three-step calculation
- V(supply):
- Supply voltage in volts
- V(forward):
- LED forward voltage at the chosen current
- I(LED):
- Target current in amperes, 0.02 for 20 mA
- Subtract the LED's forward voltage from the supply voltage. That is the voltage the resistor must drop.
- Decide the current you want, usually between 5 and 20 mA for indicator use.
- Divide the voltage across the resistor by that current.
The forward voltage depends on the LED's colour and chemistry. Typical values run from about 1.8 to 2.2 V for red and yellow, and about 3.0 to 3.4 V for blue and white, but the datasheet value at your chosen current should be used.
Worked example: 9 V supply, 2 V LED, 20 mA
Supply
9 V
LED forward voltage
2 V
Target current
20 mA = 0.02 A
Series resistor
350 Ω
Voltage across resistor = 9 − 2 = 7 V. R = 7 ÷ 0.02 = 350 Ω. Power in the resistor = 0.02² × 350 = 0.14 W.
350 Ω is not a standard value, so look at the nearest options. The preferred series has 330 Ω and 390 Ω in the E12 range, and 360 Ω in E24. Using 360 Ω gives 7 ÷ 360 = 19.4 mA. A 330 Ω part gives 21.2 mA, and 390 Ω gives 17.9 mA.
Rounding up is the safe habit. The LED will be a little dimmer than at 20 mA, but that is hard to see, and it runs cooler. Rounding down raises current above the target, which might be over the rated maximum.
As a further check, compute the brightness trade-off. Going from 20 mA to 17.9 mA is a 10% reduction in current, and the light output falls by roughly the same proportion. Human vision responds logarithmically, so most people cannot tell the difference between those two on an indicator.
If the LED must be bright in daylight, you might choose the nearest value above 20 mA within the part's datasheet limit, but never exceed the absolute maximum.
Standard values and power ratings
| Choice | Current at 9 V, 2 V LED | Resistor power | Comment |
|---|---|---|---|
| 330 Ω | 21.2 mA | 0.15 W | Slightly above the 20 mA target |
| 360 Ω | 19.4 mA | 0.14 W | Closest to target, E24 series |
| 390 Ω | 17.9 mA | 0.13 W | Cooler and a little dimmer |
| 470 Ω | 14.9 mA | 0.10 W | Clearly dimmer, longer life |
A quarter-watt resistor is comfortable here, since the dissipation is well under 0.25 W. For larger voltage drops, the resistor power I² × R grows quickly, and a half-watt or one-watt part may be needed.
Colour-specific forward voltages change the answer, so be careful when you swap a red LED for a white one on the same board. With a 3.2 V white LED on 9 V at 20 mA, the resistor drops 5.8 V and needs 290 Ω, noticeably less than the 350 Ω for the red LED.
Same LED, different supplies
The formula scales to any supply. Take the same 2 V LED at 20 mA from a 5 V rail: (5 − 2) ÷ 0.02 = 150 Ω. From 3.3 V: (3.3 − 2) ÷ 0.02 = 65 Ω, so a 68 Ω part is a good fit. From 12 V: (12 − 2) ÷ 0.02 = 500 Ω.
The efficiency of this method falls as the supply rises, because the resistor wastes the difference. At 9 V with a 20 mA current, the LED uses 2 × 0.02 = 0.04 W while the resistor takes 0.14 W as heat. About three-quarters of the power is spent in the resistor, which is acceptable for an indicator and wasteful for lighting.
- For several LEDs in series, add their forward voltages before subtracting from the supply.
- For LEDs in parallel, give each its own resistor, because forward voltages differ slightly and one may hog the current.
- For battery-powered devices, the supply voltage sags as the cell ages, so the current drifts.
What can go wrong
- Using the supply voltage without subtracting the forward voltage, which gives a resistor that is too large and a dim LED.
- Leaving milliamperes in the formula. 20 in place of 0.02 gives a value a thousand times too small.
- Forgetting polarity. LEDs only conduct one way, and a reversed LED sits dark.
- Ignoring supply tolerance. A supply that reads 9.6 V instead of 9 V raises the current in this example to about 22 mA.
Where the supply varies a lot, or you need accurate brightness, a constant-current driver is a better answer than a resistor. For everyday indicators, a resistor is simple and reliable.
Heat is another factor to remember. The LED forward voltage drops a little as the junction warms, so the current rises slightly in a hot enclosure. With a larger series drop, as in our 9 V example, the effect is small, which is another benefit of a higher supply and a bigger resistor.
Always keep the finished current below the datasheet's continuous rating, with a margin for supply variation and temperature.
Checking the finished circuit
Build it, then measure. Put a multimeter in series to read the current, or measure the voltage across the resistor and divide by its value. If the reading is close to your target, the forward voltage assumption was good. If it differs, use the measured forward voltage in the formula and re-pick the part.
An Ohm's law resistance tool computes the same division used in step three, with the resistor voltage as the input.
Common questions
How do I calculate the resistor for an LED?
Subtract the LED's forward voltage from the supply voltage, then divide by the target current in amperes. For 9 V, a 2 V LED and 20 mA, R = 7 ÷ 0.02 = 350 Ω.
What resistor should I use with a 9 V battery and a red LED?
Taking a forward voltage of about 2 V and 20 mA, the exact value is 350 Ω. Use 360 Ω from the E24 range or 390 Ω for a safer current of about 18 mA.
What happens if I use too small a resistor?
The current rises above the LED's rating, and the LED heats up, shifts colour and may burn out in seconds or fade over days. Always round the resistor value up rather than down when choosing between standard sizes.
What wattage resistor do I need for an LED?
Work out I² × R. At 20 mA across 350 Ω that is 0.14 W, so a 0.25 W resistor is adequate. If the supply is much higher than the LED voltage, the dissipation grows and a half-watt part may be needed.
Can I wire several LEDs with one resistor?
In series, yes: add the forward voltages and use one resistor for the string. In parallel, give each LED its own resistor, because small differences in forward voltage would otherwise let one branch take most of the current.
Was this guide helpful?
Continue reading
View all blogsThree-Phase Apparent Power: the √3 Formula
Three-phase apparent power in kVA = √3 × line voltage × line current ÷ 1,000. At 400 V and 25 A, a balanced load is about 17.32 kVA.
5 min read
Wire Resistance from Resistivity, Length and Area
Resistance R = ρ × L ÷ A. A 20 m copper run of 2.5 mm² (ρ = 0.0175 Ω·mm²/m) measures 0.14 Ω one way, or 0.28 Ω there and back.
5 min read
How Much Energy Does a Capacitor Store?
Stored energy E = ½ × C × V². A 1,000 µF capacitor charged to 12 V holds 0.072 J, and doubling the voltage quadruples it to 0.288 J.
5 min read




