Economics · supply & demand

Market Equilibrium Calculator

Solve for the equilibrium price and quantity where supply meets demand, see the interactive graph with shaded consumer and producer surplus.

Demand curve P = a − bQ

$

Choke price — the price at which demand falls to zero.

How much buyers' price falls per extra unit.

Supply curve P = c + dQ

$

Lowest price the first unit is supplied at.

How much sellers' price rises per extra unit.

Equilibrium quantity Q*

16

where Qd = Qs

Equilibrium price P*

$68

market-clearing price

Consumer surplus

$256

buyers' gain

Producer surplus

$384

sellers' gain

Supply & demand

Q* 16 · P* $68
027548110813401224354759CSPSDemandSupplyQuantity (Q)Price (P)

Hover or drag across the graph to read demand and supply prices at any quantity.

DemandSupplyEquilibrium

Total surplus

$640

CS + PS (max gains from trade)

Demand reaches $0 at

50 units

choke quantity

Surplus split

40% / 60%

consumers / producers

Your result

What the result means

The market clears at 16 units and $68: at that price the quantity buyers want exactly equals the quantity sellers offer, so there is no pressure for price to move.

Consumer surplus is $256 (value buyers keep above the price) and producer surplus is $384 (revenue sellers keep above cost), for $640 of total surplus — the largest the gains from trade can be in this market.

Price elasticity at equilibriumShowHide

Demand elasticity |Ed|

2.13

elastic

Supply elasticity Es

1.42

elastic

Point elasticity uses the slope and the equilibrium price/quantity. Demand here is elastic and supply is elastic. The more inelastic side bears the larger share of any tax — see the Tax & subsidy module.

Supply & demand schedule
Demand and supply price near the equilibrium quantity (preview)
QuantityDemand priceSupply priceMarket pressure
8$84$44Shortage → price rises
16$68$68◀ equilibrium (clears)
24$52$92Surplus → price falls

Scenario comparison

Save the current view (any module) to stack scenarios side by side — base case, a shift, a price control, a tax.

Save & export — from your current inputs

The Excel workbook uses live formulas — edit a, b, c, d or a policy lever on the Inputs sheet and every sheet recalculates. Inputs run in your browser and are saved locally only — never uploaded.

What this tool shows

Then simulate demand and supply shifts, price ceilings and floors, and per-unit taxes and subsidies — including who really bears the tax.

  • Equilibrium price (P*) and quantity (Q*) for linear supply and demand
  • An interactive graph with both curves, the equilibrium point, and shaded consumer and producer surplus
  • A hover read-out: demand price, supply price, and shortage/surplus at any quantity
  • A demand/supply shift simulator with scenario presets and a four-step before/after comparison
  • A price ceiling/floor module: binding test, shortage or surplus, and deadweight loss
  • A per-unit tax/subsidy module with revenue, deadweight loss, and elasticity-based incidence
  • Point price elasticity of demand and supply at the equilibrium
  • An accessible supply-and-demand schedule, scenario comparison, copy, and CSV export
  • A 15-sheet Excel workbook with live formulas — edit one input and every sheet recalculates
Transparent assumptions Interactive supply–demand graph Shift, price-control & tax modules Surplus, deadweight loss & incidence 15-sheet Excel workbook + CSV

Formula-backed supply-and-demand model with an interactive graph, surplus, deadweight loss, and tax incidence — not a market forecast.

Updated 14 June 2026 · Runs entirely in your browser

Market equilibriumThe price and quantity where the amount buyers want to buy exactly matches the amount sellers want to sell. is where quantity demanded equals quantity supplied: Q* = (a − c) ÷ (b + d), P* = a − bQ*. Enter a linear demand and supply curve and this lab solves the clearing point, shades consumer and producer surplus on an interactive graph, and lets you test shifts, price controls, and taxes — with deadweight loss and elasticity-based incidence.

At a glance

Formula shown
Q* = (a − c) ÷ (b + d), then P* = a − bQ* for linear supply and demand.
Scenario support
Shift simulator, price ceiling/floor, and tax/subsidy modules with side-by-side scenario comparison.
Workbook export
15-sheet Excel (XLSX) workbook + CSV

Where P = 100 − 2Q meets P = 20 + 3Q: 16 units at $68

Market equilibrium is the one price–quantity combination at which quantity demanded equals quantity supplied — no shortage, no surplus, and no pressure for the price to rise or fall. Finding it means setting the demand price equal to the supply price. For linear curves P = a − bQ and P = c + dQ that gives Q* = (a − c) ÷ (b + d), and substituting back gives P* = a − bQ*. Enter demand P = 100 − 2Q and supply P = 20 + 3Q and the lab returns Q* = (100 − 20) ÷ (2 + 3) = 80 ÷ 5 = 16 units, at P* = 100 − 2 × 16 = $68. If your two curves never cross at a positive quantity, the calculator floors quantity at zero rather than reporting a negative market.

That $68 is the market-clearing price: every buyer willing to pay it finds a seller, and every seller willing to accept it finds a buyer. Name any other price and the market answers back. Below $68 buyers want more than sellers offer, and the shortage bids the price up; above $68 sellers offer more than buyers want, and the surplus pushes it down. Equilibrium is the only price on the whole line with no built-in pressure to move.

Equilibrium quantity

Q* = (a − c) ÷ (b + d)

Where demand price equals supply price.

Equilibrium price

P* = a − bQ*

Substitute Q* into either curve.

Tax incidence (buyers)

share = b ÷ (b + d)

From slopes — steeper side bears more.

$256 to buyers, $384 to sellers: why no other price beats $640

The graph shades two triangles at that crossing point. Consumer surplusThe gap between the most a buyer would pay for something and the price they actually pay. is the value buyers receive above the price they actually pay; producer surplusThe gap between the price a seller receives and the lowest price they would have accepted. is the value sellers receive above their minimum acceptable price. Both are computed next to P* and Q*, not merely drawn. At the $68 equilibrium, consumer surplus = ½ × (100 − 68) × 16 = $256 and producer surplus = ½ × (68 − 20) × 16 = $384.

Together they make total surplus of $640, the gains from trade — and $640 is the most this pair of curves can produce. Any price other than $68 trades fewer units and leaves part of that $640 unclaimed, which is why the competitive equilibrium is called the efficient outcome and not merely the stable one. It is also the canonical case the engine and the 15-sheet Excel workbook are validated against on every change, so the figures on screen and the figures in the workbook agree by construction.

A $10 tax lands 40% on buyers and 60% on sellers, whoever remits it

Who bears a per-unit tax is decided by relative elasticity, not by who legally remits it — the most counter-intuitive result on this page. With linear slopes, buyers bear b ÷ (b + d) and sellers bear d ÷ (b + d): the steeper, more inelastic side carries the larger share because it is the side less able to walk away. Demand here is flatter than supply (b = 2, d = 3), so a $10 per-unit tax splits as 2 ÷ 5 = 40% onto buyers and 3 ÷ 5 = 60% onto sellers.

The same tax shrinks quantity from 16 toward 14, and those lost units are deadweight loss: mutually beneficial trades that no longer happen because the policy holds quantity away from the efficient level. On a linear diagram it is the triangle between the supply and demand curves over the units that stop trading — about $10 of surplus here, destroyed rather than transferred, captured by nobody, neither the government nor either side of the market.

A ceiling only bites below $68; a floor only above it

A price ceiling has an effect only when it is set below the equilibrium price, where it creates a shortage. A price floor has an effect only when it is set above the equilibrium price, where it creates a surplus. A ceiling above $68, or a floor below it, changes nothing at all: the market clears normally, and the module reports that rather than inventing a quantity. When a control does bind, the deadweight-loss triangle reappears, because holding the price away from $68 blocks units that both sides wanted to trade.

A shift moves the crossing point itself instead of fighting it, and the two directions behave differently: demand up raises both price and quantity, while supply up lowers the price but raises the quantity. The shift simulator lays that out as a four-step before/after comparison, so you can see which of the two coordinates actually moved and by how much — the test that separates a demand story from a supply one.

The row where quantity demanded and quantity supplied finally meet

The classroom way to find an equilibrium price is a table, not algebra: list quantity demanded and quantity supplied at each price, then scan for the row where the two match, or come closest. The accessible schedule on this page builds exactly that for whatever curves you enter, row by row, and the hover read-out on the graph does the same at any quantity — demand price, supply price, and the shortage or surplus between them.

The rows around the answer matter more than the matching row. Every price below $68 shows excess demand, every price above it shows excess supply, and the gap narrows as the rows close in on the crossing point. That column of shrinking gaps is the market signal itself: a shortage bids the price up, a surplus pushes it down, and both stop only where the gap reaches zero. Scenario comparison, copy, and CSV export carry the same rows out of the page.

Where two straight lines stop describing a real market

Every figure above is exact for a market made of two straight lines. That is the model, and its limitations are structural rather than defects — so here is what it cannot do.

Methodology

This calculator solves linear inverse demand (P = a − bQ) and supply (P = c + dQ), computes surplus as the standard welfare triangles, derives shift, price-control, tax, and subsidy outcomes analytically, and reports point elasticity and slope-based tax incidence. The engine is validated against the canonical worked case above and several hand-computed policy cases on every change, and the Excel workbook's formulas are checked with a spreadsheet formula engine against the same maths.

  • Demand and supply are assumed linear over the relevant range; real schedules can bend, kink, or shift.
  • It models a single competitive market in isolation, ignoring related markets, expectations, and time lags in adjustment.
  • Surplus, deadweight loss, and incidence are exact only for the linear model; they approximate curved real-world curves.
  • It does not forecast real prices: this is an idealised single market, and two straight lines cannot reproduce the frictions, expectations, and shocks that move actual ones.

Related calculators

Consumer SurplusFind the value buyers gain above what they pay, from the choke price, market price, and quantity sold.
Producer SurplusFind the value sellers gain above their minimum acceptable price, from the market price and quantity sold.
Deadweight LossSize the welfare triangle a per-unit tax destroys, alongside the tax revenue it actually raises.
Price Elasticity of DemandMeasure price elasticity of demand (midpoint and simple PED) and test how a price change affects revenue and profit.
Marginal UtilityTurn a utility table into total and marginal utility and utility per dollar, and find the satiation point.
Opportunity CostCompare two choices to see net value, opportunity cost, explicit vs implicit costs, and risk-adjusted scenarios.
Diminishing ReturnsTurn input-output data into total, marginal, and average product and find the point of diminishing returns.
Comparative AdvantageFind comparative and absolute advantage between two producers and two goods, plus the mutually beneficial trade range.
Break-EvenFind units and revenue break-even, contribution margin, target profit, and margin of safety, with sensitivity tables and a chart.

More in Economics, or browse all calculators.

Read the guide

There is no dedicated market equilibrium guide yet. For a deeper, two-point elasticity treatment, see the price elasticity of demand calculator.

Sources and methodology

This page solves an idealised linear supply-and-demand model from the coefficients you enter - no live prices, quantities, elasticities or tax rates are fetched. Equilibrium, consumer and producer surplus, deadweight loss and tax incidence are standard microeconomic models taught in the references below, not figures set by any government or regulator. The price series is included as a real-world contrast to the straight lines, not as an input. Links open in a new tab.

Economics & supply-and-demand disclaimer

This tool is for economics education and decision-support only. It models idealised linear supply and demand and should not be treated as a forecast of real market prices or a basis for pricing, tax-policy, or investment decisions. Real markets have curved schedules, shifting conditions, frictions, and time lags that a two-line model cannot capture. Educational explanation follows standard microeconomics (OpenStax, Principles of Economics 3e).

Inputs are processed in your browser and never stored on our servers.How we calculate · Found an error? email us

Cite this calculator

APA

Sudha, J. (2026, June 14). Market Equilibrium Calculator. Calculator Matters. https://calculatormatters.com/economics/market-equilibrium-calculator/

MLA

Sudha, Jay. "Market Equilibrium Calculator." Calculator Matters, 14 June 2026, https://calculatormatters.com/economics/market-equilibrium-calculator/.

Authorship & verification

Created and maintained by , finance educator.

What's changed (6 updates)

Published 14 June 2026

  1. Published the market equilibrium calculator: solves price and quantity from linear supply and demand, with an interactive surplus graph and shift tests.
  2. Added a downloadable Excel/CSV workbook generated from your inputs.
  3. Added visual result charts.
  4. Added side-by-side scenario comparison.
  5. Added an advanced, multi-mode planner.
  6. Reviewed the formula and assumptions for accuracy.

Add this calculator to your site

Responsive embed — and private: nothing your visitors type leaves their browser.