Consumer and Producer Surplus Calculator
Consumer surplus, producer surplus, and total surplus at market equilibrium.
About this tool
Enter linear demand and supply and, optionally, a price. Leave the price blank for the free-market equilibrium, or enter one to see surplus when the price is set elsewhere. The calculator shows both surpluses and their total.
How to use
How it works
Consumer surplus is the gap between what buyers would pay and what they do pay, summed over units. Producer surplus is the gap between what sellers receive and the least they would accept. At equilibrium the quantity is Q*. At any other price the quantity traded is the smaller of demand and supply, because the short side limits trade, and surplus is measured over that quantity.
Q = min(Qd(P), Qs(P)) CS = area between the demand curve and the price over Q PS = area between the price and the supply curve over Q
Worked example
Equilibrium, then a price of 30
- Input
- a 120; b 3; c 20; d 2; price blank, then 30
- Output
- Equilibrium: CS 600, PS 900, total 1,500. At P = 30: CS 150, PS 975, total 1,125
- Walkthrough
- At P = 20, Q = 60 and CS = ½ × 60 × (40 − 20) = 600. At a price of 30, demand is 30 and supply is 80, so only 30 units trade. The demand curve runs from 40 down to 30 over those units (average 35), so CS = 30 × (35 − 30) = 150. The supply curve runs from −10 up to 5 (average −2.5), so PS = 30 × (30 + 2.5) = 975. Total surplus drops from 1,500 to 1,125.
Limitations
- Linear curves only.
- At a non-equilibrium price it assumes trade at the short side.
Questions
What is consumer surplus?
What is producer surplus?
Why does total surplus fall at a price of 30?
How do I get surplus at equilibrium?
Features
- Equilibrium or any price
- Total surplus
- Market diagram
- Runs in your browser
Related resources
Guides and videos from around the web—opens on YouTube or the publisher’s site.
Supply and demand
Khan Academy
Equilibrium framing for the linear market tools.
Watch on YouTubeConsumer and producer surplus
Khan Academy
Surplus areas drawn on economics hub charts.
Watch on YouTube
- Principles of Microeconomics
OpenStax
Free textbook for market and tax incidence topics.
- Supply and demand
Wikipedia
Equilibrium reference for linear market calculators.