LED Resistor Calculator

Calculate the correct current limiting resistor for any LED circuit

Red
Green
Blue
White
Yellow
Orange
UV
IR

Resistor Color Bands

Circuit Diagram

How LED Resistors Work

Every LED (Light Emitting Diode) requires a current limiting resistor to operate safely. Unlike incandescent bulbs, LEDs have very low internal resistance. Without a resistor, the current would spike to destructive levels, burning out the LED in milliseconds.

The resistor value is calculated using Ohm's Law:

R = (Vs − Vf) / If

Where:

Example Calculation

For a red LED powered by a 5V Arduino:

Common LED Specifications

Different LED colors have different forward voltage drops because they are made from different semiconductor materials. Here are the typical specifications:

LED ColorForward Voltage (Vf)Typical Current (If)WavelengthResistor for 5V
Red1.8 – 2.2V20mA620–645nm150Ω
Orange2.0 – 2.2V20mA600–620nm150Ω
Yellow2.0 – 2.2V20mA585–600nm150Ω
Green2.0 – 3.2V20mA520–570nm100–150Ω
Blue3.0 – 3.4V20mA460–490nm68–100Ω
White3.0 – 3.4V20mABroad68–100Ω
UV3.1 – 3.5V20mA380–400nm68–100Ω
Infrared1.2 – 1.6V20mA850–940nm180Ω

Note: Always check your specific LED's datasheet for exact values. The numbers above are typical ranges for standard 5mm through-hole LEDs.

Arduino LED Circuit Guide

Connecting an LED to an Arduino is one of the most common beginner projects. Here's everything you need to know:

Arduino Uno / Nano (5V logic)

Arduino digital pins output 5V when set HIGH. Each pin can source up to 40mA (recommended max 20mA). For a standard red LED:

Arduino ESP32 / ESP8266 (3.3V logic)

These boards use 3.3V logic. For a red LED on 3.3V:

Arduino Code Example

Basic blink sketch for pin 13:

void setup() {
  pinMode(13, OUTPUT);
}

void loop() {
  digitalWrite(13, HIGH);  // LED on
  delay(1000);
  digitalWrite(13, LOW);   // LED off
  delay(1000);
}

Important Tips

Resistor Color Code Chart

Standard through-hole resistors use colored bands to indicate their value. Here's the complete color code reference:

ColorBand1st Digit2nd Digit3rd Digit (5-band)MultiplierTolerance
Black000×1
Brown111×10±1%
Red222×100±2%
Orange333×1K±0.05%
Yellow444×10K±0.02%
Green555×100K±0.5%
Blue666×1M±0.25%
Violet777×10M±0.1%
Grey888×100M±0.01%
White999×1G
Gold×0.1±5%
Silver×0.01±10%

Reading a 4-band resistor: Band 1 (1st digit) + Band 2 (2nd digit) + Band 3 (multiplier) + Band 4 (tolerance). Example: Brown-Black-Red-Gold = 10 × 100 = 1000Ω (1KΩ) ±5%.

Series vs Parallel LED Circuits

Series Configuration

In a series circuit, LEDs are connected end-to-end so the same current flows through all of them. You only need one resistor for the entire chain.

Parallel Configuration

In a parallel circuit, each LED (or each LED+resistor pair) is connected across the supply. Each LED needs its own resistor.

Which Should You Use?

Series is more efficient for higher voltage supplies (9V, 12V, 24V). Parallel is better when your supply voltage is low (3.3V, 5V) or when you need independent control of each LED.

Frequently Asked Questions

What resistor do I need for an LED on a 5V Arduino?
For a standard red LED (Vf = 2.0V, If = 20mA) on a 5V Arduino, the calculation is R = (5 - 2.0) / 0.020 = 150 ohms. The nearest standard resistor is 150 ohms, but many hobbyists use 220 ohms for extra safety margin, which gives about 13.6mA (still plenty bright). For blue or white LEDs (Vf = 3.2V), use 82 or 100 ohms.
Can I use one resistor for multiple LEDs?
It depends on the configuration. For LEDs in series (daisy-chained), yes, one resistor works because the same current flows through all LEDs. For LEDs in parallel, each LED should have its own resistor. Sharing a single resistor among parallel LEDs causes uneven brightness because LEDs have slightly different forward voltages, so one LED may hog most of the current.
What happens if I don't use a resistor with my LED?
Without a current limiting resistor, excessive current will flow through the LED. This can destroy the LED instantly (it may flash brightly then go dark permanently). It can also damage your Arduino or other components. The only exception is if you're using a constant-current LED driver, which already limits the current internally.
What wattage resistor should I use?
Calculate power with P = (Vs - Vf) x If. For most LED circuits with standard 20mA LEDs, the power is well under 0.25W, so a standard 1/4 watt (0.25W) resistor is fine. For higher current LEDs or higher voltages, check the calculation. Always choose a resistor rated for at least double the calculated power for reliability and to avoid overheating.
Why is my LED still dim with the calculated resistor?
Several things can cause dim LEDs: (1) The actual forward voltage of your LED is higher than expected, reducing current. (2) Your power supply voltage is lower than nominal, especially with batteries. (3) You're using a higher resistance than needed. (4) The LED itself may be low quality. Try reducing the resistor value slightly (don't go below the calculated minimum) or check your connections.