Calculators
LED Resistor Calculator
Work out the series resistor value for an LED from the supply voltage, LED forward voltage, forward current in milliamps, and how many LEDs are in series, with nearest E24 and E12 values, locally in your browser.
An LED needs a series resistor to limit its current. Enter the supply voltage, the LED forward voltage, the forward current in milliamps, and how many LEDs are wired in series. The result gives the exact resistor value, the voltage and power across it, and the nearest E24 and E12 standard values with the current and power they would produce. Calculations run locally in your browser; your values are not uploaded or stored.
Size the current-limiting series resistor for one or many LEDs.
Enter the supply voltage in volts, the LED forward voltage, the target forward current in milliamps, and the number of LEDs wired in series. The calculator uses R = (Vsupply - n x Vforward) / I to report the exact resistor value, the voltage left across the resistor, the resulting circuit current, and the power the resistor dissipates. It then shows the nearest E24 (5%) and E12 (10%) standard value with the current and power each would produce, plus a recommended power rating of at least twice the dissipation. For example, a 5 V supply driving one red LED at 1.8 V and 20 mA gives R = (5 - 1.8) / 0.020 = 160 ohms, which drops 3.2 V across the resistor and dissipates 64 mW. 160 ohms is itself an E24 value, while the nearest E12 value is 150 ohms and would run the LED at about 21.3 mA and dissipate 68 mW, so a 1/4 W part gives comfortable headroom in either case. The LED colour selector fills in a typical forward voltage, from infrared at about 1.2 V to white at about 3.3 V, and you can still type your own value. Every input must be greater than zero, the LED count must be a whole number from 1 to 1000, and the supply must exceed the total forward voltage of the string. This is an ideal-DC estimate that ignores LED tolerance, temperature drift, and supply ripple; all calculations stay in your browser.
Frequently Asked Questions
Everything you need to know about this tool, how it works, and privacy.
How do I calculate the right resistor for an LED?
Use R = (Vsupply - n x Vforward) / I, where Vsupply is the supply voltage, Vforward is the LED forward voltage, n is the number of LEDs in series, and I is the target forward current. For a 5 V supply with one red LED at 1.8 V and 20 mA, R = (5 - 1.8) / 0.020 = 160 ohms, which is itself an E24 value. When the closest standard value sits below your calculated resistance, take the next higher value instead, because a smaller resistor pushes more current through the LED.
What forward voltage should I use for my LED colour?
Typical values are about 1.2 V for infrared, 1.8 V for red, 2.0 V for orange, 2.1 V for yellow, 2.2 V for green, 3.0 V for blue, and 3.3 V for white. The colour selector fills in these values so you can start quickly, and you can replace them with the forward voltage from your LED datasheet when precision matters. Modern blue and white LEDs vary more between parts than older colours do.
How do I calculate the resistor wattage?
The resistor dissipates P = I x Vresistor, where Vresistor is the supply voltage minus the total LED forward voltage. In the 5 V red LED example, 20 mA across 3.2 V gives 64 mW, so a 1/8 W part is technically enough, but derating is wise: the calculator recommends a rating of at least twice the dissipation, so a 1/4 W resistor is a better choice for reliability and for a part running warm.
What is the difference between E24 and E12 values?
They are the two standard preferred-value series used for resistors. E24 has 24 values per decade with 5 percent tolerance, giving finer steps such as 160 and 180 ohms, while E12 has 12 values per decade with 10 percent tolerance, giving coarser steps such as 150 and 180 ohms. The calculator reports both, along with the current and power each standard value would actually produce, so you can pick the closest part from the drawer you are shopping in.
Can I calculate a resistor for several LEDs in series?
Yes. Enter how many LEDs are wired in series and their forward voltages add up, so the resistor only has the leftover supply voltage across it. The calculator requires the supply to be greater than that total forward voltage, and it reports the exact voltage left for the resistor. If the result needs an impractically large resistance, use a constant-current driver or switch to a parallel configuration with one resistor per LED instead.
Is this accurate enough for a real circuit?
It is an ideal DC estimate. Real LED forward voltage falls as the diode heats and rises at cold temperatures, resistors have a tolerance of their own, and a supply may ripple or vary. Treat the result as a starting point, check the worst case, and use the Resistor Color Code Calculator to decode the parts you buy. The calculation and copy run locally in your browser; CodeASystem does not upload or store your values.