Calculate a resistor for one LED or a series string
This LED resistor calculator finds the series resistance needed for a chosen LED current and estimates the resistor power requirement. Enter supply voltage, forward voltage per LED, target current in milliamperes and the number of LEDs in series. It is useful for indicator LEDs, simple breadboard circuits and checking a string before laying out a board.
The calculator assumes the LEDs in the string have the same forward voltage and share the same current. Its result is a nominal component calculation, rather than a simulation of the LED current-voltage curve. Copy includes the series count and the voltage and current assumptions so the saved result can be traced back to the intended circuit.
LED resistor formula and current units
For a string of N matching LEDs, R = (Vin − N × Vf) / I. Vin is the supply voltage, Vf is the forward voltage of one LED, and I must be in amperes in the formula. The input field uses mA, which the calculator converts internally. The quantity Vin − N × Vf is the voltage available across the resistor.
Choose Vf from the LED's datasheet at the intended operating current, and consider its variation with current and temperature. The forward voltage is an input assumption; this page does not calculate it from LED color, identify the LED automatically, or predict brightness. The default current is an example, not a universal recommendation for every LED.
When supply voltage is at or below the assumed total forward voltage, the page shows a supply-too-low warning. There is no positive resistor value that can produce the requested current under those assumptions. A zero or negative calculated resistance is not permission to connect the string directly across the source.
Worked example: resistor value and wattage
Use a 12 V supply, an LED forward voltage of 2 V, and a target current of 20 mA. With one LED in series, the resistor must drop the remaining voltage, and the calculator gives 500 Ω. For three identical LEDs in series at the same current, the combined forward drop is larger and the result becomes 300 Ω.
| Supply | Vf per LED | Series count | Current | Resistance | Displayed rating threshold |
|---|---|---|---|---|---|
| 12 V | 2 V | 1 | 20 mA | 500 Ω | Above 0.30 W |
| 12 V | 2 V | 3 | 20 mA | 300 Ω | Above 0.18 W |
| 5 V | 2 V | 1 | 10 mA | 300 Ω | Above 0.05 W |
| 5 V | 2 V | 2 | 10 mA | 100 Ω | Above 0.02 W |
Resistor dissipation follows P = I²R. For the first row it is 0.2 W; for the second it is 0.12 W. The page applies a 50% margin, then rounds the displayed threshold upward to the next hundredth of a watt. Choose a real resistor with a rating above that threshold, and check its temperature derating and installation conditions.
Choosing an available resistor
The calculated resistance may not match a value in your parts drawer. The tool does not automatically round to a standard resistor series. For an indicator circuit, selecting a nearby higher resistance reduces nominal current; selecting a lower one increases it. Recalculate the current for the selected part before deciding that the substitution is acceptable.
For the first example, replacing 500 Ω with an available 510 Ω resistor gives approximately 19.61 mA and 0.1961 W using the same assumed LED forward voltage. The small current reduction may be acceptable for an indicator, but its actual appearance depends on the LED and application. A power rating is a separate specification from the resistance value.
The resistor color code decoder helps identify the part you choose. Use Ohm's law to check current and resistor power when substituting a different resistance or source voltage.
Series LEDs and parallel branches
LEDs in a series string carry the same current, and their forward voltages add. The count field therefore changes the total forward drop without multiplying the target current. If the LEDs have different forward-voltage specifications, calculate the actual sum separately rather than treating the single Vf input as a prediction for every part.
Parallel branches require separate current control. For a simple resistor-limited arrangement, give each LED or series string its own resistor. Sharing one resistor across unmatched parallel LEDs can lead to uneven current distribution. This calculator sizes one series branch at a time; it does not distribute current between parallel branches or determine the total supply rating for a larger array.
Practical limits and common mistakes
A resistor is one way to limit LED current; a suitable constant-current driver is another. High-power LEDs and circuits with widely varying supply voltage often need a driver design rather than a single nominal resistor calculation. Do not assume that every LED assembly sold as a lamp is a bare diode requiring the same external resistor arrangement.
Check the largest supply voltage and the smallest plausible forward voltage when estimating maximum current. If the available resistor voltage is very small, small supply or Vf changes can cause a large current change. Also check the source's current capacity: a microcontroller output does not necessarily behave like an ideal voltage supply under load.
For a physical build, use the perfboard simulator to place the LED, resistor and connections before soldering. Its connection checks help with wiring; the current and thermal checks still come from the component values and datasheets. For more complicated resistance arrangements, the series and parallel calculator can check the equivalent network.