# LED Resistor Calculator

Calculate the resistor to use in a circuit with an LED by entering the supply voltage, forward voltage, and forward current below. Optionally calculate the resistor to accommodate multiple LEDs connected in series.

## How to Calculate the Size of Resistor to use with an LED

Light-emitting diodes, or LEDs, used in electrical circuits should be paired with a resistor to control the current. This is necessary to prevent drawing more current than the LED is rated for, which could cause damage to the component.

To determine the correct resistor value, Ohmâ€™s Law is used to derive a formula for the resistor.

### LED Resistor Calculation Formula

R_{(Ω)} = V_{s} − (V_{f} × N)I_{f}

The resistance required is equal to the supply voltage minus the forward voltage times the number of leds, divided by the forward current.

*V _{s}* – or supply voltage – is equal to the voltage supplied to the circuit.

*V _{f}* – or forward voltage – is equal to the LED voltage drop. This value is different for various color LEDs, see the chart below for the voltage drop for different LED colors.

*I _{f}* – or forward current – is equal to the current draw of the LED. Most LEDs are rated for 20-30 mA.

*N* is the number of LEDs connected in series.

**For example,** find the resistor to use for an LED with a forward voltage of 2 volts and current of 20 milliamps when using a supply voltage of 5V.

R = 5 V − 2 V0.02 A

R = 3 V0.02 A

R = 150 Ω

## Voltage Drop and Recommended Resistor Size for Various Color LEDs

Color | Typical Forward Voltage (Vf) | Supply Voltage (Vs) | Forward Current (If) | Recommended Resistor Size | Recommended Resistor Power Rating |
---|---|---|---|---|---|

Red | 2 V | 5 V | 20 mA | 150 Ω | 0.06 W |

Green | 2.1 V | 5 V | 20 mA | 145 Ω | 0.058 W |

Blue | 3.6 V | 5 V | 20 mA | 70 Ω | 0.028 W |

White | 3.6 V | 5 V | 20 mA | 70 Ω | 0.028 W |

Yellow | 2.1 V | 5 V | 20 mA | 145 Ω | 0.058 W |

Orange | 2.2 V | 5 V | 20 mA | 140 Ω | 0.056 W |

Amber | 2.1 V | 5 V | 20 mA | 145 Ω | 0.058 W |

Infrared | 1.7 V | 5 V | 20 mA | 165 Ω | 0.066 W |