LED resistor calculator
Enter the supply voltage, the LED forward voltage and the current you want. The calculator rounds up to the next standard resistor so the LED never gets more current than you asked for, and tells you the wattage to buy.
The formula
R = (Vsupply − n × Vf) ÷ I, where n is the number of LEDs in series, Vf is the forward voltage of one LED and I is the current in amps (20 mA = 0.02 A). The resistor dissipates P = I² × R.
Forward voltage depends on color and on the exact LED: red and yellow are about 1.8–2.2 V, blue, white and true green about 2.8–3.4 V. Use the datasheet value if you have it. Many modern LEDs are bright at 5–10 mA, so you can often use a larger resistor than the classic 20 mA value suggests.
Typical LED resistors
| Circuit | Current | Exact | Use | Power |
|---|---|---|---|---|
| Red LED on 5 V | 20 mA | 150 Ω | 150 Ω | 60 mW → 1/8 W |
| Red LED on 3.3 V | 15 mA | 86.7 Ω | 91 Ω | 19 mW → 1/8 W |
| White LED on 5 V | 20 mA | 90 Ω | 91 Ω | 36 mW → 1/8 W |
| Blue LED on 9 V battery | 20 mA | 290 Ω | 300 Ω | 110 mW → 1/4 W |
| 3 white LEDs in series on 12 V | 20 mA | 120 Ω | 120 Ω | 48 mW → 1/8 W |
| Red LED on 12 V | 20 mA | 500 Ω | 510 Ω | 200 mW → 1/2 W |
Each LED string needs its own resistor. Do not put several LEDs in parallel behind one resistor: small differences in forward voltage make one LED hog the current. Read the full LED resistor guide for worked examples.
Tables by supply voltage
- LED resistor for 3.3 VESP32, Raspberry Pi and other 3.3 V logic, or a 3.3 V regulator rail
- LED resistor for 5 VUSB power, Arduino Uno/Nano pins and 5 V regulator rails
- LED resistor for 9 V9 V PP3 batteries and 9 V wall adapters (guitar pedals, toys, kits)
- LED resistor for 12 V12 V adapters, LED strips, car and motorbike electrics, 12 V lead-acid batteries
- LED resistor for 24 V24 V industrial control, PLC indicators, trucks and 24 V LED strips
FAQ
What resistor do I need for an LED on 5 V?
For a red LED (≈2 V) at 20 mA: (5 − 2) ÷ 0.02 = 150 Ω. For a lower 10 mA, use 330 Ω. For a white or blue LED (≈3.2 V) at 20 mA, use 91–100 Ω.
Should I round the LED resistor up or down?
Up. A larger resistor gives slightly less current, which is safe; a smaller one overdrives the LED.
Can I use one resistor for several LEDs?
Only for LEDs in series. LEDs in parallel each need their own resistor.