Free LED resistor calculator
Size the series current-limiting resistor that runs any LED safely from your supply — enter the supply voltage, the LED's forward voltage, and the current, and the resistor value plus its wattage are updated live, as you type.
On this page13 sections
Use a resistor rated well above the calculated power dissipation. Never connect an LED directly to a power supply without current limiting.
Results are estimates. Consult a professional.
Why an LED needs a series current-limiting resistor
An LED resistor calculator finds the series resistor that lets you run a light-emitting diode safely from a given supply. An LED is a current-driven part, not a voltage-driven one: once the voltage across it passes its forward voltage, the current shoots up almost vertically for the tiniest extra volt. Wire an LED straight across a battery with no resistor and that runaway current cooks the junction in a fraction of a second — the LED flares bright, then dies.
A resistor placed in series fixes this. It soaks up the voltage left over after the LED takes its share, and because a resistor's current rises smoothly with voltage, it sets a steady, predictable current through the LED. The resistor is the cheap, reliable referee between a stiff supply and a fragile diode.
How the LED resistor calculator works
The calculation is a single application of Ohm's law to the resistor alone. The resistor has to drop whatever voltage the LED does not, while passing the current you want through the LED. Divide that leftover voltage by the target current and you have the resistance.
The two power forms are the same number written differently: since R = (V_supply − V_forward)/I, multiplying by I² gives I²R = (V_supply − V_forward) × I. This is exactly Ohm's law applied across the resistor, so the LED resistor calculator is really an Ohm's-law solver pointed at the part of the circuit you can control.
This is standard LED datasheet practice; the underlying relation is Ohm's law (V = IR) applied to the series resistor. See Ohm's law and series-circuit theory in Wikipedia's "Ohm's law" and "LED circuit" articles.The three inputs the calculator needs
Three numbers fully determine the resistor. Two come from your circuit and one comes from the LED's datasheet.
Supply voltage (V_supply)
The voltage feeding the LED branch — a 5 V USB rail, a 9 V battery, a 12 V vehicle line, or a 3.3 V microcontroller pin. It must be larger than the LED's forward voltage, otherwise the LED never lights and the calculator cannot return a value.
Forward voltage (V_forward)
The voltage the LED itself drops once it is conducting. This depends mostly on colour, because colour is tied to the semiconductor chemistry: red LEDs sit near 2 V, while blue and white LEDs sit near 3.2 V. Read it from the datasheet where possible; the table further down gives typical ranges when you cannot.
Forward current (I_forward)
The current you want flowing through the LED, in milliamps. 20 mA is the long-standing default for ordinary 5 mm indicator LEDs and is what most datasheets rate brightness at. Running below the rating (say 5–10 mA) is perfectly fine and just gives a dimmer, cooler, longer-lived LED; running above the rating risks early failure.
A worked example: a red LED on 5 volts
Sam wants to add a power indicator to a 5 V USB project. The LED is an ordinary red 5 mm part with a forward voltage of 2 V, and the datasheet rates it at 20 mA. What series resistor keeps it safe?
Step 1 — Find the leftover voltage
The resistor must drop whatever the LED does not: V_supply − V_forward = 5 − 2 = 3 V.
Step 2 — Divide by the target current
Convert 20 mA to amps (0.02 A), then R = 3 ÷ 0.02 = 150 Ω. That is the exact resistance the calculator reports.
Step 3 — Pick a standard value
150 Ω is itself a standard E12 value, so you can buy it directly. If 150 Ω is not in your parts drawer, round up to the next standard value — 220 Ω — which lowers the current slightly to about 13.6 mA. Rounding up is always the safe direction: a bigger resistor means less current, never more.
Step 4 — Check the resistor's wattage
The power the resistor must shed is P = (5 − 2) × 0.02 = 0.06 W, or 60 mW. A common 1/4-watt (0.25 W) resistor handles that with a four-fold margin, so any garden-variety resistor works here.
Typical LED forward voltages and currents
Forward voltage tracks LED colour, and current is usually 20 mA for standard indicators. Use these typical values when you do not have a datasheet, but treat the datasheet as the final word — forward voltage varies between manufacturers and rises a little at higher current.
| LED colour | Typical V_forward | Typical current |
|---|---|---|
| Infrared | 1.2–1.6 V | 20–100 mA |
| Red | 1.8–2.2 V | 20 mA |
| Orange / yellow | 2.0–2.2 V | 20 mA |
| Green (standard) | 2.0–2.4 V | 20 mA |
| Green / blue (high-brightness) | 3.0–3.4 V | 20 mA |
| Blue / white | 3.0–3.4 V | 20 mA |
| Ultraviolet | 3.4–4.0 V | 20 mA |
Typical 5 mm indicator-LED values; always confirm V_forward and the maximum current against the datasheet for your specific part.
Worked through the formula for a 20 mA LED, these give the resistor you need at common supplies. The "round-up" column is the next standard E12 value at or above the exact figure — read off the bands with a resistor colour code chart.
| Supply | LED (V_forward) | Exact R | Round up to |
|---|---|---|---|
| 5 V | Red (2.0 V) | 150 Ω | 150 Ω |
| 5 V | Blue/white (3.2 V) | 90 Ω | 100 Ω |
| 9 V | Red (2.0 V) | 350 Ω | 390 Ω |
| 12 V | Red (2.0 V) | 500 Ω | 560 Ω |
| 12 V | Blue/white (3.2 V) | 440 Ω | 470 Ω |
| 3.3 V | Red (1.8 V) | 150 Ω | 150 Ω |
All rows assume 20 mA. Exact R = (V_supply − V_forward) / 0.02; the round-up column is the nearest E12 standard value at or above it.
Choosing the resistor's power rating
Resistance is only half the choice — the resistor must also survive the heat it makes. The power is P = (V_supply − V_forward) × I_forward, and you buy a resistor rated comfortably above it. Standard through-hole resistors come as 1/8 W (0.125 W), 1/4 W (0.25 W), 1/2 W and 1 W. A good rule is to pick a rating at least twice the calculated power so the part runs cool.
- Low-voltage indicators (5 V, 20 mA): the resistor sheds 60 mW or so — any 1/4 W resistor is fine.
- 12 V at 20 mA: the drop is larger, so the resistor handles 0.2 W. A 1/4 W part is marginal at full load; a 1/2 W resistor is the comfortable choice.
- High-current or automotive use: once power passes ~0.25 W, step up to a 1/2 W or 1 W resistor, and remember it will get noticeably warm.
Driving several LEDs: series vs parallel
Lighting more than one LED changes the arithmetic, and the series-versus-parallel choice matters more than beginners expect.
LEDs in series — one resistor, voltages add
Stack LEDs end to end and their forward voltages add up, so a single resistor sets the current for the whole string. Three red LEDs (3 × 2 V = 6 V) on a 12 V supply at 20 mA need R = (12 − 6) ÷ 0.02 = 300 Ω (round up to 330 Ω). This is the efficient layout — one resistor, less wasted voltage — but the supply must exceed the combined forward voltage.
LEDs in parallel — one resistor each
Do not put several LEDs in parallel behind one shared resistor. Real LEDs differ slightly in forward voltage, so the one with the lowest V_forward hogs most of the current and runs hot while the others stay dim — a problem called current hogging. Give each parallel LED its own series resistor so each branch is limited independently.
Common LED resistor mistakes
- No resistor at all. "It's only an LED" is how LEDs die. Even a 3 V coin cell can over-drive a 2 V red LED; the internal resistance of the cell is the only thing saving it, and that is not a design.
- Rounding the resistor down. Always round up to the next standard value. A smaller resistor pushes more current and shortens LED life; a slightly larger one only dims the LED a touch.
- Using supply voltage as the drop. The resistor drops V_supply − V_forward, not the full supply. Forgetting to subtract V_forward sizes the resistor too high — harmless but dim — or, if you also mis-handle it, too low.
- Ignoring the wattage. A correctly-valued resistor can still burn out if it is under-rated for power. Check P, especially on 12 V and higher rails.
- Sharing one resistor across parallel LEDs. Current hogging makes the brightness uneven and can overload one LED. One resistor per parallel branch.
How accurate is this LED resistor calculator
The arithmetic is exact: for the supply voltage, forward voltage, and current you enter, R = (V_supply − V_forward) / I_forward and P = (V_supply − V_forward) × I_forward are computed to full floating-point precision. The result is the ideal resistor; real circuits then land close to it rather than exactly on it, for physical reasons.
- Resistor tolerance. Stock resistors are typically ±1% (E96) or ±5% (E12/E24), so the real current sits a few percent either side of target. LEDs tolerate this easily.
- Forward-voltage spread. The biggest uncertainty is V_forward itself — it varies between parts and rises slightly with current and falls with temperature. A 0.2 V error here moves the resistor value more than the resistor's own tolerance does.
- Rounding to standard values. Because you round up to the nearest stock resistor, the built current is usually a little below the target — which is the safe direction.
For an indicator LED none of this matters; 20 mA versus 17 mA is invisible to the eye. Treat the calculated resistor as the design value, round up to a standard part, and confirm the wattage. For the underlying theory, see Ohm's law and the Wikipedia "LED circuit" reference linked above.
Frequently asked questions about the free LED resistor calculator
About this LED resistor calculator
This LED resistor calculator runs entirely in your browser — nothing is sent to a server. Enter your supply voltage, the LED's forward voltage, and the target forward current in milliamps, and it applies Ohm's law to the series resistor — R = (V_supply − V_forward) / I_forward — to return the exact resistance, the power the resistor dissipates, and a suggested standard value, recalculating instantly as you type.