LED Resistor Calculator
Calculate the series resistor required to drive an LED safely.
Step-by-step calculation
- R = (12 V − 2 V) ÷ 0.02 A
- R = 500 Ω (Nearest E12: 470 Ω | E24: 510 Ω | E96: 499 Ω)
- Power = 10 V × 0.02 A = 0.2 W (Recommended rating ≥ 2×: 1/2 W (0.5 W))
Formula
Input definitions
| Symbol | Input | Unit | Meaning & code relevance |
|---|---|---|---|
| V_s | Supply Voltage | V | Nominal RMS AC or steady-state DC system potential (e.g., 120V/240V/480V NEC or 230V/400V IEC 60038). |
| V_f | LED Forward Voltage | V | Nominal RMS AC or steady-state DC system potential (e.g., 120V/240V/480V NEC or 230V/400V IEC 60038). |
| I_LED | Target LED Current | mA | Steady-state operating load current in amperes; compare with NEC Table 310.16 or IEC 60364-5-52 conductor ampacity. |
Worked example
Standard 2V Red LED on 12V Supply
Limit current to 20 mA.
- Drop across resistor = 12 − 2 = 10 V
- R = 10 ÷ 0.020 A = 500 Ω (use 510 Ω 1/2W)
Assumptions
- The DC supply voltage (V_s) is regulated and exceeds the LED forward voltage (V_f).
- The LED forward voltage drop remains approximately constant at the target operating current.
- Recommended resistor power rating includes a 2× thermal derating margin above actual I²R dissipation.
Limitations
- For high-power LEDs (>1W / >350mA) or automotive supplies where voltage swings from 12V to 14.4V, use a constant-current buck driver instead of a passive resistor.
- Never wire LEDs directly in parallel sharing a single resistor — slight V_f differences cause current hogging and thermal runaway.
How it works
Subtracts the diode forward voltage drop from the DC supply voltage and applies Ohm’s Law to cap LED current safely.
When to use it
- Calculating the exact current-limiting series resistor (R = (V_s − N × V_f) ÷ I_f) for a single LED or multiple LEDs wired in series.
- Selecting the nearest standard EIA E12/E24 resistor value and verifying safe resistor power dissipation (P = I² × R with a 2× thermal safety margin).
- Designing 5 V Arduino/ microcontroller indicators, 12 V automotive/camper LED circuits, and 24 V industrial control panel status lamps.
Practical real-world applications
- Microcontroller & PCB Prototyping: Sizing a 220 Ω or 330 Ω 1/4 W resistor to drive a 2.0 V red or 3.2 V blue/white indicator LED safely from a 3.3 V or 5.0 V GPIO pin.
- 12V / 24V DC Series LED Strings: Wiring 3 white LEDs (V_f = 3.2 V each, total 9.6 V) in series on a 12 V DC bus with a single 120 Ω current-limiting resistor to minimize wasted heat.
- Industrial Pushbutton & Pilot Light Retrofits: Dropping 24 V DC PLC output voltage down to 20 mA panel indicator LEDs using properly rated 1 W or 2 W resistors.
Original Editorial Review & Technical Evaluation
Calculates the exact series current-limiting resistor value (Ω), minimum resistor wattage rating (with 2× thermal margin), and nearest standard E12/E24 resistor value for LED circuits.
Embedded electronics engineers, makers/hobbyists, and indicator-panel technicians wiring single or series LED strings on DC rails.
- Computes R = (V_source − N × V_f) ÷ I_LED alongside exact resistor thermal dissipation P = I²R
- Automatically recommends nearest commercial E12 and E24 resistor values and safe power rating (≥ 2× P_loss)
- Flags negative headroom errors if series forward voltage exceeds DC supply voltage
Accuracy & methodology: Treats LED forward voltage drop (V_f) as a fixed constant at the target forward current (I_LED) on a regulated DC supply. Unregulated automotive (12V–14.8V) or battery supplies must be evaluated at maximum peak charging voltage to prevent LED over-current. Computational standards →
What to verify independently: Check LED maximum continuous forward current (I_f,max) and V_f vs. temperature curves in the component datasheet.
Put the numbers to work with the Ohm's Law Calculator, Power Calculator and Resistor Series & Parallel Calculator. For the background behind the numbers, read How to Choose Electronic Components and How to Choose Bench Equipment & Soldering Gear.
Common mistakes
- Entering LED forward current in milliamps (e.g., 20) directly into a formula expecting Amperes (0.020 A) without converting, which under-calculates resistance by 1,000×.
- Wiring multiple LEDs directly in parallel sharing a single current-limiting resistor (slight V_f differences cause one LED to hog current and burn out in a cascade).
- Selecting a 1/8 W or 1/4 W resistor when dropping high voltage (e.g., 24 V down to 2 V at 20 mA dissipates 0.44 W, requiring at least a 1 W resistor for safe thermal margin).
Safety & code notice
Calculator results are planning estimates. Always verify electrical designs against applicable local codes, standards (NEC / IEC), and consult a qualified professional.
Frequently asked questions
Related Calculators
Ohm's Law Calculator
Calculate voltage, current, resistance, and power in DC or resistive AC circuits.
Power Calculator
Calculate active, apparent, and reactive power from voltage, current, or PF.
Resistor Series & Parallel Calculator
Calculate total equivalent resistance and drops for series or parallel resistors.
Parallel Resistor Calculator
Calculate exact equivalent resistance and branch currents of parallel resistors.
Related Unit Converters
Electrical Resistance Converter (mΩ, Ω, kΩ, MΩ, GΩ)
Convert resistance between milliohms, ohms, kilohms, megohms, gigohms, and S.
Voltage Unit Converter (V, mV, µV, kV, MV)
Convert electrical potential across SI decades from microvolts to megavolts.
Electrical Current Converter (A, mA, µA, kA)
Convert electrical current across SI decades from microamperes to kiloamperes.
Electrical Frequency & Motor Speed Converter (Hz, kHz, MHz, GHz, rad/s, RPM)
Convert between Hz, kHz, MHz, GHz, angular velocity, period, and motor RPM.
Related Engineering Guides
Recommended Bench Multimeters & Soldering Equipment for Component Work
Verify component resistance and capacitance out-of-circuit with an auto-ranging True-RMS multimeter and use a temperature-controlled ESD-safe soldering station for clean joints.

Weller WE1010NA Digital Soldering Station
A 70 W temperature-controlled soldering station with a digital readout for consistent joints.
- 70 W element — recovers heat quickly on larger joints instead of stalling mid-solder.
- Digital temperature setpoint — repeatable settings job to job, rather than a vague dial position.
- Adjustable temperature range — works for fine electronics and heavier control wiring with one station.

AstroAI DM6000AR True-RMS Digital Multimeter
A true-RMS 6000-count meter with temperature, capacitance and a CAT III 600 V rating — the budget option for DIY, hobby and student work.
- True-RMS AC measurement — accurate readings on the distorted, non-sinusoidal waveforms that switch-mode supplies, dimmers and inverters produce, which is where average-sensing meters quietly mislead.
- 6000-count display with 0.1 mV and 0.1 µA resolution — more resolution on low-voltage and low-current work than a typical 2000-count budget meter, so small changes are visible rather than rounded away.
- CAT III 600 V and CAT II 1000 V safety rating — rated for the transient energy of distribution panels and fixed wiring, not just bench work.

Klein Tools 11063W Wire Stripper and Cutter
Self-adjusting stripper that grips, strips and cuts common building wire in one motion.
- Self-adjusting action — squeeze once and the tool sets itself to the conductor size, so strips are repeatable.
- Clean strip without nicking — protects the copper, which is what keeps a termination reliable long term.
- Built-in cutter and plier nose — you can cut, strip and twist without swapping tools.

Fluke 117 True-RMS Multimeter
The everyday electrician's meter: true-RMS AC measurement, non-contact voltage detection and a CAT III 600 V rating in a compact body.
- True-RMS AC measurement — accurate readings on the electronic loads that fool cheaper average-sensing meters.
- Built-in non-contact voltage detection — confirm a circuit is live before you put a probe anywhere near it.
- CAT III 600 V safety rating — rated for the transient energy you meet in distribution panels and fixed wiring.