{{ summaryHeading }}
{{ summaryPrimary }}
{{ summaryLine }}
{{ badge.label }}
Op amp gain inputs
Select the feedback path you want to calculate.
{{ solveModeHelp }}
{{ targetGainDisplay }}
{{ targetGainHelp }}
V/V
{{ feedbackHelp }}
{{ gainResistorHelp }}
{{ primaryInputHelp }}
Use 0 V for split supplies or the virtual ground for single-supply circuits.
Set the positive and negative supply rails used for the swing check.
+V V
-V V
Use a preset to verify the workflow or start from a common sensor, audio, bridge, or mixer stage.
Load preset
Use the op-amp data sheet typical GBW value.
The highest signal frequency you expect this gain stage to pass.
Used to flag large high-frequency output swings.
V/us
Approximate tolerance band for the gain ratio.
%
Use a rail-to-rail value such as 0.1 to 0.3 V, or larger for older op-amps.
V
Load resistance from output to the reference point.
Adjust output decimals without changing the calculation.
Metric Value Detail Copy
{{ row.label }} {{ row.value }} {{ row.detail }}
Check Status Detail Copy
{{ row.label }} {{ row.value }} {{ row.detail }}

        
Customize
Advanced
:

Closed-loop op-amp gain is the voltage gain set by a feedback network around an operational amplifier. The op amp still provides the active drive, but the external resistor ratio usually decides how much a small input voltage becomes at the output.

That ratio matters in sensor front ends, audio stages, filters, level shifting, lab fixtures, and analog-to-digital converter drivers. A gain stage may need to lift a millivolt signal into a useful range, invert a signal around a reference voltage, subtract two inputs, or add two channels before another circuit reads the result.

Op amp feedback loop with input resistor, feedback resistor, reference node, output, and usable rail limits.

Ideal gain equations are useful only while the amplifier can stay in its linear range. Supply rails, output headroom, load current, gain-bandwidth product, slew rate, input common-mode range, resistor tolerance, and layout stability can all move a real circuit away from the simple resistor-ratio result.

Use the calculated gain as a first-pass design check. For a circuit that will ship, drive an analog-to-digital converter, or handle a fast waveform, confirm the selected op-amp data sheet limits and test the built stage at the intended signal amplitude and frequency.

How to Use This Tool:

Start by choosing the feedback circuit and calculation goal. You can analyze resistor values you already have, solve the feedback resistor from a target gain, or solve the input/gain resistor from a target gain.

  1. Choose Topology. Non-inverting keeps the signal phase, Inverting flips it around the reference voltage, Differential subtracts one input from the other, and Inverting summing adds two weighted input currents at the inverting node.
  2. Set Calculation goal. Analyze uses the entered network directly, Solve Rf computes the feedback resistor from the target gain, and Solve Rg/Rin computes the matching gain or input resistor.
  3. Enter Target gain when a solve mode is active. Non-inverting solves require a target gain greater than 1 V/V. Inverting, differential, and summing solves use the absolute gain magnitude and apply the sign from the topology.
  4. Enter the visible resistor fields. The second resistor label changes between Gain resistor Rg, Input resistor Rin, and First input resistor R1 so the visible fields match the selected circuit; solve modes hide the resistor being calculated.
  5. Enter the input voltage fields in mV or V. Differential mode uses Positive input V+ and Negative input V-; summing mode uses First input V1, Second input V2, and Second input resistor R2.
  6. Set Reference voltage. Use 0 V for a split-supply circuit, or the virtual-ground bias for a single-supply circuit where the output must swing around a mid-rail reference.
  7. Set Supply rails and, in Advanced, Output headroom. The Output swing check compares the ideal output with the usable rail window after headroom is subtracted from both rails.
  8. Use Design presets to load common sensor, audio, bridge, or mixer examples, then adjust the values for your circuit.
  9. Use Advanced for Gain-bandwidth product, Signal frequency, Slew rate, Resistor tolerance, Output load, and Display precision. These controls drive the design checks and displayed decimals without changing the selected topology.
  10. Read Gain Snapshot first for closed-loop gain, gain in dB, output voltage, noise gain, bandwidth, input impedance, and load current. Then check Design Checks and the Output Transfer Curve before using the values in a schematic.

If validation appears, fix the named input before reading the result. Common causes are zero-valued resistors, a positive rail that is not greater than the negative rail, headroom that leaves no linear output range, gain-bandwidth product at zero, resistor tolerance at 20% or higher, or a negative load value.

Interpreting Results:

The headline gain is the signed closed-loop signal gain for the selected topology. Positive gain means the output moves in the same direction as the active input term. Negative gain means the output moves in the opposite direction around the reference voltage.

The output voltage should be checked with the Output swing, Bandwidth, Slew rate, and Load current rows. A result that is Within rails only says the ideal output fits inside the entered rail window. It does not prove that the chosen op amp has enough input common-mode range, output drive, phase margin, or distortion performance for the circuit.

How to read op amp gain calculator outputs
Output What to check Common misread
Closed-loop gain Use the sign and V/V value to confirm phase and resistor-ratio gain. Treating the sign as an error when the inverting and summing topologies should return negative gain.
Output voltage Compare ideal output with rail-limited output. A clipped value means the requested stage cannot produce the ideal swing with the entered rails and headroom. Using the rail-limited number as a clean linear output.
Noise gain Use it for the quick closed-loop bandwidth estimate and stability intuition. Confusing signal gain with noise gain in an inverting circuit.
Estimated closed-loop bandwidth Compare it with Signal frequency. Comfortable results have at least a 10x margin in this quick check. Reading the estimate as a flatness or distortion guarantee.
Slew rate Compare required V/us with the entered op-amp value. Tight and Insufficient need a faster op amp, lower output amplitude, or lower frequency. Checking small-signal bandwidth while ignoring large-signal slope demand.
Gain tolerance Use it as a worst-case resistor-ratio estimate from the entered tolerance. Assuming it includes op-amp offset, bias current, temperature drift, or resistor tracking.

For a critical design, verify the calculator output against the data sheet values for input common-mode voltage, output swing at load, output current, gain-bandwidth product, slew rate, capacitive-load stability, and resistor tolerance over temperature.

Technical Details:

Negative feedback lets a large open-loop amplifier behave like a smaller, predictable voltage gain stage. In the ideal model, the op amp drives its output until the inverting and non-inverting inputs are nearly equal. The external network then fixes the signal gain, input impedance, and the output voltage needed to satisfy that feedback condition.

The equations below use a reference voltage so single-supply and split-supply circuits can be modeled with the same sign convention. A 0 V reference is the usual choice for bipolar supplies. A mid-rail reference is common when a single-supply circuit needs headroom above and below the signal.

Formula Core:

The output equations calculate the ideal linear output before rail limiting. The final displayed output is then clamped to the usable rail window when the ideal value exceeds the entered supply limits and headroom.

Non-inverting = Vref + (1+RfRg) (Vin-Vref) Inverting = Vref - RfRin (Vin-Vref) Differential = Vref + RfRin (V+-V-) Inverting summing = Vref - Rf ( V1-VrefR1 + V2-VrefR2 )

The rail and speed checks use the ideal output amplitude because clipping and slew-rate demand both depend on the waveform the circuit is trying to produce.

Vhigh = V+-H Vlow = V-+H fclosed = GBWnoise gain SR required = 2pifVpeak1000000
Op amp gain formula symbols and meanings
Symbol Meaning Where it appears
Rf Feedback resistor from output to the inverting input node. All topologies
Rg, Rin, R1, R2 Gain or input resistors that set the signal ratio. The selected topology determines which names are visible.
Vref Reference voltage or virtual ground used as the output center point. All voltage equations
H Output headroom subtracted from each rail before the linear swing check. Rail-limit equations
GBW Gain-bandwidth product from the selected op-amp data sheet. Closed-loop bandwidth estimate
Vpeak Absolute ideal output amplitude measured from the reference voltage. Slew-rate estimate

Noise gain is equal to the non-inverting closed-loop gain for a non-inverting circuit. For inverting and differential circuits here, it is estimated as one plus the feedback-to-input resistor ratio. For the summing circuit, the input resistance term is the parallel combination of the two input resistors.

Op amp calculator design check rules
Check Rule used Meaning
Output swing High rail clip above the high limit, Low rail clip below the low limit, Tight swing when margin is below 0.5 V, otherwise Within rails. Flags whether the ideal output fits the entered supply rails after headroom.
Bandwidth Comfortable when estimated bandwidth is at least 10x signal frequency, Tight from 2x to below 10x, and Too narrow below 2x. Gives a quick small-signal margin check from gain-bandwidth product and noise gain.
Slew rate Comfortable when available slew rate is at least 2x required, Tight from 1x to below 2x, and Insufficient below 1x. Checks whether a sine wave with the ideal output amplitude can be followed without slope limiting.
Resistor range Below 1 kohm is flagged as low, above 100 kohm asks for noise review, and above 1 Mohm is flagged as high. Reminds the designer that practical resistor values affect source loading, noise, bias-current error, and parasitic sensitivity.
Load current Below 5 mA is Light load, 5 mA to below 20 mA is Moderate load, and 20 mA or above is Heavy load. Estimates output current into the entered load resistance relative to the reference voltage.
Validation boundaries for op amp gain inputs
Input Accepted values Why it matters
Feedback and gain resistors Greater than 0 after ohm, kohm, or Mohm conversion. Zero or negative resistance breaks the gain ratio.
Input voltages and reference voltage Finite numeric values in mV or V. The output equation depends on each voltage relative to the reference.
Supply rails Positive rail must be greater than negative rail. The usable output window needs a real high and low limit.
Output headroom 0 V or greater, and small enough to leave a linear window between the rails. Headroom models the output swing that the op amp cannot use near each supply rail.
Gain-bandwidth product Greater than 0 after Hz, kHz, or MHz conversion. Bandwidth is estimated by dividing this value by noise gain.
Signal frequency and slew rate Frequency must be 0 or greater; slew rate must be 0 or greater. Frequency drives the bandwidth and slew checks. A 0 Hz signal is treated as a DC check.
Resistor tolerance 0% to below 20%. The gain-tolerance estimate uses a worst-case resistor-ratio spread.
Output load 0 or greater after resistance-unit conversion. A value of 0 skips load-current estimation; positive values estimate output current.

The transfer curve samples a local input range around the entered input value. It plots both ideal output and rail-limited output, so clipping appears as a flattened curve at the entered high or low limit rather than as a separate failure state.

Accuracy Notes:

The calculator uses ideal feedback equations plus quick first-order checks. It does not model every device-specific effect.

  • Check input common-mode range and output swing against the actual op-amp data sheet, especially on single-supply circuits.
  • Use the bandwidth and slew-rate rows as screening checks, not as distortion or stability guarantees.
  • Review input bias current, input offset voltage, resistor temperature drift, resistor matching, capacitive load, and PCB layout for precision or high-speed stages.
  • Simulate and bench-test circuits that operate near the rails, near the op amp's speed limits, or into heavy loads.

Worked Examples:

A non-inverting sensor stage with Rf = 10 kohm, Rg = 2 kohm, Vin = 250 mV, Vref = 0 V, and +/-5 V rails gives Closed-loop gain of +6.000 V/V. The Output voltage is 1.500 V, Gain in dB is 15.56 dB, and the default 10 MHz gain-bandwidth product gives about 1.667 MHz Estimated closed-loop bandwidth. With a 10 kHz sine target, the Slew rate check stays comfortable because the required slope is about 0.094 V/us.

An inverting stage with Rf = 47 kohm, Rin = 10 kohm, Vin = 2.0 V, Vref = 0 V, +/-5 V rails, and 0.2 V output headroom asks for an ideal output near -9.4 V. The result shows Closed-loop gain of -4.700 V/V, but Output swing becomes Low rail clip because the usable low limit is -4.8 V. Reducing gain, reducing input amplitude, raising the negative rail, or changing the reference point is required before the stage can stay linear.

A differential check with Rf = 20 kohm, Rin = 10 kohm, V+ = 1.80 V, V- = 1.65 V, and Vref = 0 V returns a 2.000 V/V differential ratio and about 300 mV at Output voltage. That result is useful for a first subtraction check, but a real difference amplifier also needs matched resistor ratios and common-mode range review before it can reject the shared input voltage accurately.

A summing setup with Rf = 10 kohm, R1 = 10 kohm, V1 = 100 mV, V2 = 50 mV, and R2 accidentally left at 0 shows a validation message that Second input resistor R2 must be greater than zero. Setting R2 to 4.7 kohm produces an inverted sum of about -206.38 mV at Output voltage, with the second input weighted more strongly because its resistor is smaller.

FAQ:

Why does non-inverting gain include plus one?

In a non-inverting stage, the input is applied directly to the positive input and the feedback divider returns only a fraction of the output to the negative input. The output must rise enough for that divided feedback voltage to match the input, so the closed-loop gain is 1 + Rf/Rg.

Why can an inverting gain be less than one?

The inverting signal gain is -Rf/Rin. If Rf is smaller than Rin, the magnitude is below 1 V/V and the circuit attenuates while still reversing polarity around the reference voltage.

Why does bandwidth use noise gain?

Noise gain is the gain seen by the op amp's input error voltage, and it is the relevant value for a quick closed-loop bandwidth estimate. In a non-inverting stage it matches signal gain, but in an inverting stage it is usually one higher than the absolute signal-gain ratio.

Does Within rails mean the real op amp will work?

No. Within rails means the ideal output fits between the entered rail limits after output headroom. You still need the data sheet to check input common-mode range, output current, output swing at the chosen load, stability, noise, and distortion.

How do I fix the headroom validation error?

The error appears when the entered headroom consumes the full supply span. Reduce Output headroom, increase the rail separation, or correct a rail entry so the positive rail is above the negative rail with usable voltage left between them.

Glossary:

Closed-loop gain
The signal gain after feedback is connected around the op amp.
Feedback resistor
The resistor from output back to the inverting input node, named Rf in the equations.
Reference voltage
The voltage that the output swings around, often 0 V or a single-supply virtual ground.
Noise gain
The gain applied to op-amp input error voltage, used for bandwidth and stability intuition.
Gain-bandwidth product
A data-sheet speed value used to estimate closed-loop bandwidth from noise gain.
Slew rate
The fastest output voltage change the op amp can produce, usually entered in V/us.
Output headroom
The voltage margin reserved near each supply rail before checking linear output swing.