LED, supply, and target current in - ideal and E12 resistor out.
💡 Typical forward voltages: red/amber 1.8-2.2 V, green 2.0-2.4 V, blue/white 3.0-3.4 V. 20 mA is the classic indicator current; modern high-efficiency LEDs are bright enough at 2-5 mA. In series, add the forward voltages — and keep the total under the supply.
The LED Resistor Calculator is based on the following formula:
R = (V_supply − V_forward) ÷ I_LED R_E12 = smallest E12 value ≥ R I_actual = (V_supply − V_forward) ÷ R_E12 P_R = I_actual² × R_E12
Variables: V_supply = Supply or battery voltage (V) V_forward = LED forward voltage at target current (V) I_LED = Desired LED current (A; 20 mA = 0.02) R_E12 = Nearest standard 10/12/15/18/22/27/33/39/47/56/68/82 series value (Ω) P_R = Power burned in the resistor (W)
The resistor takes whatever voltage the LED does not and turns it into the current you chose. Rounding up to the next E12 value guarantees the LED never sees more than the target current.
Worked example: Step 1: 12 V supply, white LED V_f 3.2 V, target 20 mA → R = (12 − 3.2) ÷ 0.02 = 8.8 ÷ 0.02 = 440 Ω. Step 2: 440 is not an E12 value → round up to 470 Ω. Step 3: I_actual = 8.8 ÷ 470 = 0.018723 A ≈ 18.72 mA. Step 4: P_R = 0.018723² × 470 = 0.1648 W ≈ 165 mW → use a 1/2 W resistor (≈3× headroom). Result: 470 Ω gives 18.72 mA — 94% brightness at safe current.
An LED's current rises exponentially with voltage: half a volt too many and milliamps become hundreds of milliamps, and the junction cooks. The resistor's only job is to absorb the difference between supply and forward voltage and convert it into the exact current you chose.
Red and amber LEDs sit around 1.8-2.2 V, green 2.0-2.4 V, blue and white 3.0-3.4 V — white is effectively a blue LED plus phosphor. The forward voltage matters twice over: it sets the resistor value, and in series strings the total forward voltage must stay below the supply.
Standard resistors come in the E12 ladder — 10, 12, 15, 18, 22, 27, 33, 39, 47, 56, 68, 82 times each power of ten. Always round up: a bigger resistor means less current, and less current costs a few percent brightness while more current costs the LED.
The calculator shows the resistor's dissipation; pick a part rated at least twice that, four times in sealed enclosures. A 1/4 W resistor running at 200 mW is fine on a breadboard and toasty inside a 3D-printed case — heat has nowhere to go in a sealed box.
More tools you might find useful
Grep-style filtering for logs — keyword, level, or regex.
Generate placeholder text for mockups and designs.
Turn Markdown into clean HTML with live preview.
Extension ↔ MIME type mapping for HTTP headers and configs.