Op-Amp Gain Calculator

Gain, error, bandwidth and clipping of feedback stages.

  • Four stage types
  • Finite-gain error
  • Bandwidth limit
A small round wooden stool holding a soft clay slab with a curved row of clay beads along one side.

The guide

Feedback swaps a huge gain nobody can control for a small gain anyone can set, and bandwidth pays for it

Why an op-amp stage's gain is a ratio of resistors, why the non-inverting one is one plus that ratio, and what a finite open-loop gain, a gain-bandwidth limit and the supply rails each take away.

  • -10 and 11 gains for Rf 100 k with R1 or Rg 10 k
  • 0.011 percent fall in gain at a noise gain of 11, A0 100,000
  • 90.9 kHz closed-loop bandwidth at gain 11, GBW 1 MHz
  • -5.1257 V summing output for 0.5, -0.3 and 0.7 V
  • -15 V where a -20 V output stops on 15 V rails
Read the full guide Fold the guide 6 min · 14 sources

An operational amplifier on its own is nearly useless as an amplifier. Its gain without feedback is enormous, typically around 100,000 or 100 decibels, and the manufacturing process does not control it tightly.

Feedback fixes that by giving most of the gain away. Harold Stephen Black invented the negative feedback amplifier in 1927, and the bargain he described is still the whole story: the circuit sacrifices gain for linearity, and as a side effect it gains bandwidth. In exchange the gain stops depending on the amplifier and starts depending on two resistors.

What feedback does to a gain that is too large to use

Send a fraction of the output back to the input where it subtracts from the signal. Call the open-loop gain A and the returned fraction B. The output is A times the difference between the input and B times the output, and rearranging gives a closed-loop gain of A divided by one plus A times B.

When A is huge, that is close to one over B. The amplifier’s own gain has cancelled out of the answer, leaving only the feedback network, which is usually a simple, reproducible pair of resistors. This is the reason every circuit on this page has an Rf, a resistor from the output back to the input.

The word “close” carries the rest of the essay. The gain is exactly one over B only when A is infinite. A real part has a large but finite A, and that leaves a small error that the tool computes and shows.

Why the non-inverting gain is one plus a ratio

Feed the signal into the non-inverting input and tie the other input to a divider made of Rf and Rg. The divider returns Rg over (Rf plus Rg) of the output, so B is that fraction and one over B is one plus Rf over Rg.

There is a simpler reading. The output must rise until the divider hands back exactly the input voltage. With the input at 1 V and Rf equal to Rg, the output has to be 2 V, since only half of it comes back. The gain is 2, not 1.

A quick answer often gives Rf over Rg here and forgets the one. With Rf at 100 k and Rg at 10 k that answer is 10, and the true gain is 11. The extra one is the input itself, passed straight through. It also explains a limit. A non-inverting stage cannot have a gain below 1, because the output always contains the whole input plus whatever the resistors add.

The virtual ground, and why it is allowed

Now take the inverting stage, where the signal goes through R1 into the inverting input and the other input is grounded. Two facts do the work. The amplifier has a very large gain, so its two inputs end up at almost the same voltage. And it draws almost no current into those inputs.

So the inverting node sits at ground without being wired to ground. That is a virtual ground: a node held at a steady potential by something other than a direct connection. Kirchhoff’s current law then does the rest, because the currents meeting at that node add to zero. The current V in over R1 has nowhere to go but through Rf, so the output is minus Rf times that current, which is minus Rf over R1 times the input.

For Rf at 100 k and R1 at 10 k the gain is -10 and the stage flips the sign. With an input of 0.5 V the output is -5 V. The non-inverting stage with the same Rf and a 10 k Rg has a gain of 11, so the gains are -10 and 11 for the two cases.

The method has a condition. It needs a large open-loop gain, and an input impedance large compared with the resistors in the feedback network. Resistors in the kilohm range suit it, because values much above a megohm bring thermal noise and errors from bias or leakage currents.

Several inputs can share one virtual ground. Each input resistor feeds its own current into the node, the currents add, and the output is minus Rf times the sum of each voltage over its resistor. Take Rf at 100 k and inputs of 0.5 V, -0.3 V and 0.7 V through 10 k, 22 k and 47 k. The output is -5.1257 V, and the currents at the node balance to exactly zero.

A differential stage drives both inputs. Its output is a weighted difference, and it rejects a voltage common to both inputs only when R1 over Rf equals R2 over Rg. With 10 k and 100 k pairs matched, the gain from V2 is 10 and the gain from V1 is -10.

How a finite open-loop gain leaves a small error

Rework the node equations with the output equal to A times the voltage difference, where A is finite. Every stage gives the same result: the ideal output divided by one plus the noise gain over A.

The noise gain is one plus Rf times the sum of one over each resistor that meets the inverting node. It is 11 for both stages above. With A equal to 100,000 the factor is one over 1.00011, so the inverting gain becomes -9.99890 and the non-inverting gain becomes 10.99879. Both are low by 0.011 percent. That is small, and it shrinks in proportion to A. It is also more serious than it looks for a high-gain stage. A noise gain of 1,000 with the same A loses 1 percent, because the error is the noise gain divided by A.

Bandwidth, the rail, and what the model leaves out

The open-loop gain is not flat. The common model has one pole: the gain is A at low frequency and falls steadily after a corner, so that the product of gain and frequency stays constant. That constant is the gain-bandwidth product, and a part with a product of 1 MHz has a gain of 1 at 1 MHz. Wired for a gain of 10 it works up to about 100 kHz.

Feedback does not break this. It moves along the same line. The closed-loop pole sits at the product divided by the noise gain, and the exact single-pole answer adds the term 1 over A, giving the product times (1 over A plus 1 over the noise gain). For a noise gain of 11 and a product of 1 MHz the exact value is 90,919 Hz and the approximation is 90,909 Hz. The two differ by 0.011 percent, the same figure as the gain error. Round it to 90.9 kHz.

The bandwidth here is the half-power point: the frequency at which the output has fallen to 0.707 of its low-frequency value, which is 3 decibels down. A stage with a gain of 100 on the same part reaches only about 10 kHz. Gain and bandwidth trade one for one.

The last limit is the supply. The output cannot go beyond the rails, and older parts stop one or two volts short of them, while rail-to-rail parts get to within millivolts at low output currents. This page takes the headroom from you, because it holds no data sheet.

Ask the inverting stage with a gain of -10 to handle an input of 2 V, and the ideal output is -20 V. On 15 V rails the output stops at -15 V. A clipped waveform approaches a square wave, which adds strong high harmonics, so clipping is a distortion and not just a smaller number.

The model uses ideal inputs and a single pole. It ignores offset voltage, bias current, slew rate, noise and the limits that capacitive loads put on stability, and it says nothing about filters, integrators or comparators. A real part’s data sheet is where those live.

Two cautions about the exact fractions the page uses. Resistor ratios are kept as exact integers, using BigInt, so -10 and 11 come out as -10 and 11 and never as 9.999999. And the heavier work, the response curve and the table, runs in a worker thread so typing never stalls.

Check the arithmetic yourself. Type Rf as 100k and R1 as 10k, switch to the non-inverting stage with Rg at 10k, and read 11. Remove the 1 and you get the common wrong answer of 10, which is the one error this page exists to catch.

Sources

Every source consulted for this guide. Links checked November 11, 2026.

  1. Operational amplifier applications Wikipedia (CC BY-SA)
  2. Operational amplifier Wikipedia (CC BY-SA)
  3. Virtual ground Wikipedia (CC BY-SA)
  4. Gain-bandwidth product Wikipedia (CC BY-SA)
  5. Negative-feedback amplifier Wikipedia (CC BY-SA)
  6. Differential amplifier Wikipedia (CC BY-SA)
  7. Open-loop gain Wikipedia (CC BY-SA)
  8. Kirchhoff's circuit laws Wikipedia (CC BY-SA)
  9. Cutoff frequency Wikipedia (CC BY-SA)
  10. Harold Stephen Black Wikipedia (CC BY-SA)
  11. Clipping (audio) Wikipedia (CC BY-SA)
  12. Negative feedback Wikipedia (CC BY-SA)
  13. Web Workers API MDN Web Docs (CC BY-SA)
  14. BigInt - JavaScript MDN Web Docs (CC BY-SA)