LED Resistor Calculator

Pick your supply, LED color and current. You get the exact value, the standard resistor to buy and its color bands.

Frequently Asked Questions

How is the LED resistor calculated?

R = (supply voltage − LED forward voltage × number of LEDs) ÷ current. The result is rounded up to the next E12 standard value so the LED is never over-driven.

What current should I use?

Most 5 mm indicator LEDs are happy at 10-20 mA. ESP32 and Raspberry Pi pins should stay well under 20 mA each.

Can I run an LED from a 3.3 V pin?

Red, yellow and green LEDs work well from 3.3 V with a small resistor. Blue and white LEDs need about 3 V, so they may be dim; use a transistor and a 5 V supply for full brightness.

Educational use only. Results are estimates from standard formulas and typical values, provided "as is" without warranty. Always check your part's datasheet and follow safety precautions. Arduino, ESP32, ESP8266 and Raspberry Pi are trademarks of their respective owners; TechsPassion is not affiliated with them. See the full disclaimer.