Home / Tools / LM317 voltage regulator calculator

LM317 voltage regulator calculator

Set the output of an LM317 adjustable regulator with two resistors. Get the voltage from the resistors you have, or the resistor for the voltage you want, plus how hot it will get.

  • Electronics tool
  • Runs in your browser
  • Tested 19 November 2026
  • Sources
TI's typical application uses 240 Ω.
Use k, M, m, µ (or u), for example 240, 4k7 or 20m.
Leave blank to use R2 above.

The formula

The LM317 keeps 1.25 V (VREF) between its output and ADJ pins. R1 sets a current of 1.25 V ÷ R1, which also flows through R2, along with a small current from the ADJ pin (IADJ, typically 50 µA). From the Texas Instruments datasheet:

VOUT = 1.25 × (1 + R2 / R1) + IADJ × R2

Worked example. R1 = 240 Ω and R2 = 720 Ω: 1.25 × (1 + 3) + 0.00005 × 720 = 5.04 V. For 12 V with R1 = 240 Ω, R2 = (12 − 1.25) ÷ (1.25/240 + 0.00005) = 2,044 Ω, so 2 kΩ (E24) gives 11.8 V, or 2.05 kΩ (E96) gives 12.0 V.

Design checks

  • Headroom. The datasheet specifies operation with 3 V to 40 V between input and output, and says it may need up to 3 V to stay in regulation. Keep the input at least 3 V above the output at your lowest supply voltage.
  • Tolerance. VREF can be 1.2 V to 1.3 V, so the output can be about ±4 % from the calculated value before resistor tolerance. Use 1 % resistors, or a trimmer for R2, if it matters.
  • Minimum load. The regulator needs at least 3.5 mA (typical, 10 mA worst case) flowing out of it. With R1 = 240 Ω, R1 itself draws 5.2 mA, which is why that value is common.
  • Heat. The regulator dissipates (VIN − VOUT) × ILOAD. Above about 1 W it needs a heatsink. Use the heatsink calculator to size one.
  • A 0.1 µF input capacitor and a 1 µF output capacitor are recommended. Check the datasheet for your version.

Sources

Where the formulas and figures on this page come from. We test every tool against worked examples from these before publishing.