LED Resistor Calculator
Work out the series resistor an LED needs from the supply voltage, forward voltage and target current, with the nearest standard value.
Everything you type here is processed on your own device. No input is sent to a server, logged, or stored.
What the LED Resistor Calculator does
Use this LED resistor calculator to work out the series resistor an LED needs from the supply voltage, forward voltage and target current, with the nearest standard value. Fill in all 4 fields and the result updates as you type — there is no Calculate button to press and no page reload. It is most often used for adding an indicator LED to a circuit or a microcontroller pin. For a second version of this LED resistor calculator, see FreeToolStation.org.
How to use it
- Enter the supply voltage.
- Enter the LED's forward voltage from its datasheet — the colour-based figures in the hint are approximate.
- Set the target current, usually 20 mA for a standard indicator LED.
- Read the resistor value, the nearest standard part, and the power rating you need.
How it works
An LED is a diode, not a resistor. Its current rises steeply once forward voltage is reached, so connecting one straight across a supply either produces nothing or destroys it, with very little voltage between the two outcomes. The series resistor is what turns an unstable voltage-driven device into a predictable current-driven one.
If the supply voltage is below the combined forward voltage the LEDs will not light at all — the voltage-across-the-resistor figure goes negative, which is the signal that you need fewer LEDs in series or a higher supply.
Derate the resistor. A part dissipating close to its rated power runs hot enough to drift in value and to be unpleasant to touch; the convention is to choose a rating of at least twice the calculated dissipation.
When to use it
- Adding an indicator LED to a circuit or a microcontroller pin.
- Building an LED strip or array from discrete parts.
- Working out whether a chain of LEDs will run from a given supply.
- Checking an existing design against the current the LED is rated for.
Common mistakes to avoid
- Driving an LED without a resistor or a constant-current driver.
- Using a colour-based forward voltage instead of the datasheet figure.
- Exceeding a microcontroller pin's current limit, which is often 20 mA per pin and much lower in total.
- Choosing the right resistance in a package that cannot dissipate the power.
Frequently asked questions
What resistor do I need for an LED on 5 V?
For a red LED at 2.1 V forward and 20 mA, about 145 Ω — so a standard 150 Ω part. For a blue or white LED at 3.2 V, about 90 Ω, so 100 Ω.
Can I put LEDs in parallel on one resistor?
Not reliably. Small differences in forward voltage mean one LED takes most of the current and the others stay dim. Give each branch its own resistor.
What if my supply voltage is lower than the forward voltage?
The LED will not light. You need a boost converter, a lower-forward-voltage LED, or fewer LEDs in the series chain.