How to Calculate an LED Resistor for SMD LEDs

An LED resistor is calculated by subtracting the LED’s forward voltage (Vf) from the supply voltage and dividing by the desired current: R = (Vsupply − Vf) / I. To drive a 2.0 V red SMD LED at about 10 mA from a 5 V supply, you get (5 − 2.0) / 0.010 = 300 Ω; the nearest higher value in the E12 series, 330 Ω, is chosen. To get the right value, read Vf and current from the LED’s datasheet instead of guessing. In this article we work through 5 V, 3.3 V and 12 V examples step by step using the datasheet values of three 0603 SMD LEDs.
Most calculators use a single number such as “red 2 V, green 3 V, 20 mA”. Real datasheets give a range for Vf, and that range can swing the LED current far more than expected, especially at low supply voltages. The examples below show this effect as well.
Why is an LED driven through a series resistor?
An LED is a diode: below its forward voltage threshold it passes almost no current, and once past the threshold the current rises quickly with a small increase in voltage. Connecting an LED directly to a voltage source therefore leaves the current uncontrolled. The Lite-On LTST-C191KRKT datasheet also describes the LED as a current-operated device and recommends limiting the current with a resistor in series with the LED. The TOGIALED datasheet gives the same warning: without a protection resistor, a slight voltage shift causes a large change in current and the LED can burn out.
The series resistor takes the part of the voltage that does not drop across the LED. By Ohm’s law, this voltage and the resistor value set the current through the circuit. The resistor can be on either the anode or the cathode side of the LED; in a series circuit the current is the same in both cases.

LED resistor calculation formula
By Kirchhoff’s voltage law, Vsupply = VR + Vf. Since the voltage across the resistor is VR = I × R:
R = (Vsupply − Vf) / I
The calculated value usually does not match a standard resistor value. Choosing the next higher standard value lowers the current slightly, which is the safe side for the LED. Then recalculate the actual current with the selected resistor:
I = (Vsupply − Vf) / R
The last step is to find the power dissipated in the resistor: P = I² × R, or equivalently P = (Vsupply − Vf) × I.
Datasheet values of the three SMD LEDs in the examples
The table below is taken from the datasheets of the three 0603 (1608 metric) indicator LEDs used in the calculations. Electrical values are for 25 °C ambient temperature.
| Parameter | LTST-C191KRKT (red) | LTST-C193TGKT-5A (green) | TJ-S1608SW6TGLC2R-A5 (red) |
|---|---|---|---|
| Manufacturer | Lite-On | Lite-On | TOGIALED |
| Semiconductor | AlInGaP | InGaN | AlGaInP |
| Forward voltage (Vf) | typ. 2.0 V, max. 2.4 V | 2.50–3.10 V | 1.8–2.4 V |
| Vf test current | 20 mA | 5 mA | 20 mA |
| Continuous forward current (absolute max.) | 30 mA | 20 mA | 30 mA |
| Peak current (pulsed) | 80 mA (1/10 duty, 0.1 ms) | 100 mA (1/10 duty, 0.1 ms) | 125 mA (1/8 duty, 1 kHz) |
| Power dissipation (max.) | 75 mW | 76 mW | 72 mW |
| Reverse voltage | 5 V | not designed for reverse operation | 5 V |
| Luminous intensity | min. 10, typ. 54 mcd (20 mA) | 28–280 mcd (5 mA) | min. 60, typ. 120 mcd (20 mA) |
| Operating temperature | −55 … +85 °C | −20 … +80 °C | −40 … +80 °C |
Two important points follow from the table. First, the forward voltage of the green InGaN LED is clearly higher than that of the red ones. Second, the green LED’s Vf and luminous intensity are specified at 5 mA; 20 mA is its continuous current limit, not an operating point.
Step-by-step example calculations
Example 1: red LED on a 5 V supply (LTST-C191KRKT)
- Choose the target current: 10 mA is enough for an indicator LED. This is one third of the 30 mA continuous current limit.
- Take Vf from the datasheet: typ. 2.0 V.
- Calculate the resistor: R = (5 − 2.0) / 0.010 = 300 Ω. 300 Ω is a value in the E24 series; if you use the more common E12 series, choose the next higher value, 330 Ω.
- Find the actual current: I = (5 − 2.0) / 330 ≈ 9.1 mA. If Vf is at its worst case of 2.4 V, I = (5 − 2.4) / 330 ≈ 7.9 mA.
- Check the power: for the resistor P = (0.0091)² × 330 ≈ 27 mW; for the LED 2.0 V × 9.1 mA ≈ 18 mW. This is well below the LED’s 75 mW limit.
Note: the Vf value in the datasheet is measured at 20 mA. When the current drops to 10 mA, Vf falls slightly, so the actual current comes out a little higher than calculated. Because we left a wide margin to the 30 mA limit, this difference does not cause a problem.
Example 2: green LED on a 5 V supply (LTST-C193TGKT-5A)
This LED’s Vf range is 2.50–3.10 V (at 5 mA), and the datasheet gives no typical value. Let’s calculate with the midpoint of the range, 2.8 V, and then check both ends.
- Target current: 5 mA (the datasheet’s test current).
- R = (5 − 2.8) / 0.005 = 440 Ω. Next higher standard value: 470 Ω.
- For an LED with Vf = 3.10 V: I = (5 − 3.10) / 470 ≈ 4.0 mA.
- For an LED with Vf = 2.50 V: I = (5 − 2.50) / 470 ≈ 5.3 mA.
With the same resistor, the current stays between 4.0 and 5.3 mA, which is an acceptable range for the design. The bigger factor in brightness differences is the LED’s own luminous intensity bin: the datasheet gives a spread of 28 to 280 mcd at 5 mA.
Example 3: the same green LED on a 3.3 V supply
Suppose we drive the same green LED through 100 Ω on a 3.3 V microcontroller board:
- Vf = 3.10 V: only 0.2 V remains across the resistor, I = 0.2 / 100 = 2.0 mA.
- Vf = 2.50 V: 0.8 V remains across the resistor, I = 0.8 / 100 = 8.0 mA.
Because Vf changes with current, the real extremes come out a bit closer than this rough calculation, but two LEDs in the same circuit can still differ in current by a factor of two to four. The datasheet’s Vf bin table also gives a ±0.1 V tolerance for each bin, so in practice Vf can reach 3.2 V; in that case only about 1 mA flows through 100 Ω. The Lite-On LTST-C191KRKT datasheet recommends that the forward current should not change by more than 40% of its desired value under worst-case voltage variations. At 3.3 V the green LED cannot meet this criterion. The solution is to power the LED from 5 V, use a red LED with a lower forward voltage, or switch to a constant-current driver.

Example 4: red LED on a 12 V supply (TJ-S1608SW6TGLC2R-A5)
- Target current: 10 mA.
- Vf range 1.8–2.4 V (at 20 mA); midpoint 2.1 V. R = (12 − 2.1) / 0.010 = 990 Ω. Standard value: 1 kΩ.
- Current range: between (12 − 2.4) / 1000 = 9.6 mA and (12 − 1.8) / 1000 = 10.2 mA.
- Resistor power: in the worst case P = (0.0102)² × 1000 ≈ 0.104 W.
At a high supply voltage the current is very stable, but now the resistor heats up. About 0.1 W can be close to the limit of a small SMD resistor package. Check the power rating in your resistor’s datasheet and leave a margin of at least twice the calculated power. In this example, 0.104 W calls for a resistor rated at about 0.2 W or more. Halving the current is another solution: with 2 kΩ (E24; 2.2 kΩ in E12) the current is at most (12 − 1.8) / 2000 ≈ 5.1 mA, and the resistor power is about 52 mW.
What to watch for when choosing and using SMD LEDs
- Take Vf from the datasheet, not from the color. Even LEDs of the same color can be made from different semiconductors. The two red LEDs above have similar Vf values, while the green InGaN LED goes up to 3.10 V.
- Mind the test current. Luminous intensity and Vf apply at the current stated in the datasheet. For the LTST-C193TGKT-5A this current is 5 mA; for the other two it is 20 mA.
- Derate the current at high temperature. The continuous current limit of the LTST-C191KRKT decreases by 0.4 mA for every degree above 25 °C. For example, at 60 °C ambient the limit becomes 30 − 0.4 × 35 = 16 mA. Keep the current low for other LEDs that will run at high temperatures as well.
- Check polarity against the datasheet drawing. Manufacturers mark the cathode in different ways. The Lite-On drawings label the cathode terminal “CATHODE”, while the TOGIALED datasheet uses pin numbers 1 and 2 with a diode symbol. If you are not sure, test with the diode mode of a multimeter.
- Protect against ESD. Lite-On states that static electricity can damage the LEDs and recommends a grounded wrist strap or anti-static gloves. The TOGIALED datasheet also marks the LED as an electrostatic-sensitive device.
Common mistakes
- Connecting several LEDs in parallel with a single resistor. The Lite-On datasheets recommend a separate series resistor for each LED. With a single resistor, the LED with the lower Vf draws most of the current and the LEDs light at different brightness levels.
- Calculating with typical Vf and not checking the worst case. As Example 3 shows, when the supply voltage is close to Vf, the tolerance can change the current several times over.
- Treating the absolute maximum current as the operating current. 20 mA or 30 mA is the limit the LED can withstand. Indicator LEDs are often bright enough well below that.
- Forgetting the resistor power. When the supply voltage exceeds twice Vf, the resistor dissipates more power than the LED; even at 5 V in Example 1, the resistor dissipates 27 mW and the LED 18 mW. At 12 V the difference becomes very large.
- Exposing the LED to reverse voltage. The reverse voltage limit of the two red LEDs in the examples is 5 V, and the LTST-C193TGKT-5A is not designed for reverse operation. Avoid reverse voltage as much as possible. In circuits with AC or a risk of reverse connection, a diode can be added in anti-parallel with the LED.
Measurement steps for hobbyists: find the LED’s actual current
You do not need to measure current to verify the calculation on the circuit; two voltage measurements are enough:
- Power the circuit and set the multimeter to DC volts.
- Measure the voltage across the two ends of the resistor (VR).
- Calculate the current: I = VR / R. For example, if you measure 3.0 V across 330 Ω, the current is about 9.1 mA.
- Measure the voltage across the LED; this is the actual Vf at that current. The two measurements should add up to the supply voltage.
According to the ESD note in the LTST-C193TGKT-5A datasheet, at 0.1 mA the Vf of a good InGaN LED should be above 2.0 V and that of a good AlInGaP LED above 1.4 V. Because a multimeter’s diode mode may use a different test current, this comparison is only a rough check; a very low Vf or high reverse leakage current can indicate that the LED is damaged.
If you want to drive many LEDs from a microcontroller, see the driving LEDs with the 74HC595 article; for high-current LED strips, see the using a MOSFET with Arduino article. A similar series resistor calculation appears in the Zener diode series resistor calculation article.
Frequently asked questions
What resistor value do I need for an LED at 5 V?
It depends on the LED’s Vf and the current you want. To drive a 2.0 V red LED at about 10 mA, 330 Ω is suitable; to drive the green LTST-C193TGKT-5A, with a Vf of 2.50–3.10 V, at about 5 mA, 470 Ω is suitable.
Does the LED resistor go on the anode or the cathode side?
It does not matter. Since the same current flows through every element in a series circuit, the resistor does the same job on either side of the LED.
Why do blue, green or white LEDs light weakly or unevenly at 3.3 V?
The forward voltage of InGaN LEDs is close to 3.3 V. For example, the Vf of the LTST-C193TGKT-5A can reach 3.10 V; in that case very little voltage remains across the resistor, and the current changes several times over depending on the Vf tolerance.
What should I do if the calculated value is not a standard value?
Choose the next higher standard value and recalculate the current. A larger resistor reduces the current slightly; the LED lights a little dimmer but stays within its limits.
Can I connect a battery to an SMD LED without a resistor?
This is not recommended. The LED’s forward voltage curve is steep; when the supply voltage rises slightly above Vf, the current increases rapidly. Datasheets call for a series resistor to limit the current.
Conclusion
Calculating an LED resistor starts with a single formula, but the Vf range and test current in the datasheet determine the right result. The higher the supply voltage is above Vf, the more stable the current, at the cost of more heat in the resistor. Always check the calculation with the minimum and maximum Vf, then check the resistor power. You can find the LTST-C191KRKT, LTST-C193TGKT-5A and TJ-S1608SW6TGLC2R-A5 LEDs used in the examples, along with other models, in the indicator LEDs category, and series resistors in the SMD chip resistors category.
References
Ask Claude or ChatGPT about the parts in this article and their alternatives: your assistant brings them from our catalog with stock and prices.
How do I connect?Products in this article
-
$0.04LTST-C191KRKT
Lite-On Inc. · EE02043-3LED RED CLEAR SMD177 In Stock -
$0.11LTST-C193TGKT-5A
Lite-On Inc. · EE01369-2LED GREEN CLEAR CHIP SMD100 In Stock -
$0.033TJ-S1608SW6TGLC2R-A5
TOGIALED · EE02268-1LED RED CLEAR 0603 SMD162 In Stock
More from Electronics Basics
- Electronics BasicsIntermediate
Active vs Passive Buzzer: Differences and Arduino Wiring
An active buzzer sounds at its own tone on DC; a passive one needs a square wave. TMB12A12 and SFN piezo values, Arduino wiring…
9 min read
- Electronics BasicsIntermediate
What Is the 74HC595? Wiring Diagram and Driving LEDs
What is the 74HC595 and how do you wire it? Step by step: pinout, the SER, SCK and RCK signals, daisy-chaining, and resistor calculation…
10 min read
- Electronics BasicsIntermediate
What Is a Zener Diode? Series Resistor Calculation and Reading the Code
What is a Zener diode and how does it work? Series resistor calculation, reading the voltage from 1N47xx and BZX55C codes, power selection and…
10 min read


