LED resistor calculator
This LED resistor calculator finds the current limiting resistor for one LED or a string of LEDs in series: enter the supply voltage, the LED color or its forward voltage, the current and the number of LEDs. It gives the exact resistance, the next standard E12 or E24 value, the real current with that resistor, the power it dissipates and a suggested wattage, and handles several strings in parallel.
LED resistor calculator: series resistor and its power rating
How to use the LED resistor calculator
Choose what you want to calculate, then enter the supply voltage, pick the LED color (or type the forward voltage from the datasheet), and enter the current you want and the number of LEDs in series. The LED resistor calculator returns the exact resistance, rounds it up to the next value of the E12 or E24 standard series, recalculates the real current with that standard resistor, and gives the power the resistor dissipates with a suggested wattage. The second mode handles several identical strings in parallel and adds up the supply current. The third mode works backward: enter a resistor you already have and see what current your LEDs will get. Each result has “Show the working” with the numbers substituted, and a small schematic of the circuit.
The formula behind the LED resistor calculator
An LED is a diode: once the voltage across it reaches its forward voltage Vf, the current rises very steeply with a little more voltage. It cannot be connected straight to a battery or power supply; something has to set the current. The simplest way is a series resistor. The resistor takes whatever voltage the LEDs do not, and by Ohm’s law that fixes the current:
PR = I² × R = (Vs − n × Vf) × I
Here Vs is the supply voltage, n the number of LEDs in series in one string, Vf the forward voltage of one LED at the chosen current, and I the LED current in amperes (20 mA = 0.020 A). The calculated resistance is rarely a value you can buy, so the LED resistor calculator picks the next standard value above it: a slightly larger resistor gives slightly less current, which is the safe direction. With n LEDs in series every LED carries the same current, so one resistor serves the whole string. If the string voltage n × Vf is equal to or above the supply, the LEDs will not light properly, and the calculator tells you to use fewer LEDs per string.
LED resistor calculator example: two red LEDs on 9 V
Two red LEDs in series, with a typical forward voltage of 2.0 V each, are powered from a 9 V battery at 20 mA. These are the default values of the LED resistor calculator.
- String voltage: 2 × 2.0 V = 4.0 V, so the resistor must drop 9 − 4.0 = 5.0 V.
- Exact resistance: R = 5.0 V / 0.020 A = 250 Ω.
- Next E12 value at or above 250 Ω: 270 Ω (the value below, 220 Ω, would give 22.7 mA).
- Real current: 5.0 V / 270 Ω = 18.52 mA, a little under the target, which is fine.
- Resistor power: (0.01852 A)² × 270 Ω = 0.0926 W = 92.6 mW. Doubled for margin that is 0.185 W, so a common 1/4 W resistor is enough.
The whole circuit draws 9 V × 18.52 mA = 0.167 W, and only 4.0/9 = 44.4 % of it reaches the LEDs; the rest is heat in the resistor. If each LED actually drops 1.9 V instead of 2.0 V, the current rises to 19.26 mA, which shows why a margin of a volt or more across the resistor keeps the current stable.
Typical LED forward voltage by color
The forward voltage depends mainly on the semiconductor, and so on the color. The ranges below are rounded from the color table in the light-emitting diode article; the HyperPhysics page on light-emitting diodes (Georgia State University) explains the physics behind them. The “value used” column is the typical figure the LED resistor calculator applies when you pick a color. White LEDs are blue InGaN chips with a phosphor, so they behave like blue ones. Treat all of these as starting points and read the datasheet: two red LEDs from different makers can differ by a few tenths of a volt.
| Color | Wavelength | Forward voltage range | Value used (typical) | Material |
|---|---|---|---|---|
| Red | 610–760 nm | 1.6–2.0 V | 2.0 V | AlGaAs, GaAsP, GaP |
| Orange | 590–610 nm | 2.0–2.1 V | 2.1 V | GaAsP, GaP |
| Yellow | 570–590 nm | 2.1–2.2 V | 2.1 V | GaAsP, GaP |
| Green | 500–570 nm | 1.9–4.0 V | 2.2 V (GaP yellow-green), 3.2 V (InGaN true green) | GaP, AlGaP, InGaN |
| Blue | 450–500 nm | 2.5–3.7 V | 3.2 V | InGaN, SiC |
| White | blue chip + phosphor | 2.7–3.5 V | 3.2 V | InGaN |
| Violet / UV | below 450 nm | 2.8–4.4 V | 3.4 V | InGaN, AlGaN |
Standard resistor values follow the IEC 60063 preferred-number series. E12 (12 values per decade, for 10 % parts): 10, 12, 15, 18, 22, 27, 33, 39, 47, 56, 68, 82. E24 adds 11, 13, 16, 20, 24, 30, 36, 43, 51, 62, 75 and 91. The LED resistor calculator picks from these, each multiplied by a power of ten, so 27 also means 270 Ω, 2.7 kΩ and 27 kΩ. To read the bands on the resistor you buy, use the Resistor Color Code Calculator.
Parallel strings and resistor wattage
When the supply is too low for all your LEDs in one string, split them into several identical strings in parallel. Each string needs its own resistor: if one resistor feeds several LEDs in parallel, the LED with the lowest forward voltage takes most of the current, gets hotter, drops even less voltage and can fail, after which the others take its share. In the LED resistor calculator, three strings of two red LEDs need three 270 Ω resistors and draw 3 × 18.52 = 55.6 mA from the battery. For the battery runtime of such a load, see the Battery Life Calculator.
The resistor power is P = I² × R. The LED resistor calculator suggests a part rated for at least twice the dissipation, a common rule of thumb that keeps the resistor cool; 1/4 W through-hole resistors cover almost all single indicator LEDs. When the resistor would waste more than about a watt, as with 350 mA or 700 mA power LEDs, a constant-current LED driver is the better choice. The general power relations P = V × I, V²/R and I²R are covered by the Electrical Power Calculator.
Common mistakes with an LED resistor calculator
- Using milliamps as amps. 20 mA is 0.020 A; dividing 5 V by 20 gives 0.25 Ω, not 250 Ω. Pick the unit in the menu and the LED resistor calculator converts it for you.
- Rounding down to the nearest value. A lower resistor means more current than planned. Round up, as the LED resistor calculator does, unless you have checked the higher current against the datasheet.
- Ignoring the supply tolerance. A “9 V” battery starts near 9.5 V and ends near 7 V; a 12 V car system runs at about 14 V while charging. Calculate the resistor at the highest voltage the circuit will see.
- Too little headroom. With 3.2 V white LEDs on 3.3 V, only 0.1 V is left for the resistor, and the current is set by tiny differences in forward voltage. Keep at least 15 % of the supply across the resistor; the LED resistor calculator warns you when you do not.
- Forgetting the power rating. A 1/8 W resistor dropping 7 V at 20 mA (0.14 W) runs hot. Check the wattage line.
For a resistor that sets a reference voltage rather than a current, the Voltage Divider Calculator is the right tool, and the Parallel Resistor Calculator combines resistors when you need a value you do not have.
Related calculators
Browse all electrical calculators, or use the Ohm’s Law Calculator for any voltage, current and resistance problem.
- Resistor Color Code Calculator
- Ohm’s Law Calculator
- Voltage Divider Calculator
- Parallel Resistor Calculator
- Electrical Power Calculator
- Battery Life Calculator
- All electrical calculators
Frequently asked questions
What resistor do I need for an LED on 5 V?
For one red LED (about 2.0 V) at 20 mA: R = (5 − 2.0)/0.020 = 150 Ω, a standard value. For one blue or white LED (about 3.2 V) at 20 mA: (5 − 3.2)/0.020 = 90 Ω, so use 100 Ω, which gives 18 mA. Enter your own LED values in the LED resistor calculator to check.
Can I use one resistor for several LEDs?
Yes for LEDs in series, because they all carry the same current. No for LEDs in parallel: give each parallel LED or string its own resistor, or one LED takes most of the current.
What happens if I use a larger resistor than the LED resistor calculator gives?
The current and the brightness drop a little and the LED runs cooler and lasts longer. Many indicator LEDs are clearly visible at 5 to 10 mA, so a larger resistor is usually fine.
What wattage resistor do I need for an LED?
Calculate P = I² × R (or the voltage across the resistor times the current) and choose a resistor rated for at least twice that, as the LED resistor calculator does. For one or two small LEDs at 20 mA this is usually 1/4 W.
Why does the LED resistor calculator round up the resistance?
The exact result is rarely a standard value. Rounding up keeps the current at or below your target, which protects the LED; rounding down would push it above.
Is this LED resistor calculator free?
Yes. It runs in your browser, needs no sign-up and does not store or send the values you enter.