GDP Calculator
- Updated
- Formula shown
- Free, no sign-up
Results
GDP = $700 billion + $180 billion + $200 billion + ($120 billion − $150 billion) = $1,050 billion.
- Consumption (C)
- $700 billion
- Investment (I)
- $180 billion
- Government (G)
- $200 billion
- Net exports (X − M)
- −$30 billion
| Component | Amount | Share of GDP |
|---|---|---|
| Consumption (C) | $700 billion | 66.7% |
| Investment (I) | $180 billion | 17.1% |
| Government (G) | $200 billion | 19% |
| Net exports (X − M) | −$30 billion | −2.9% |
| GDP | $1,050 billion | 100% |
The default numbers describe a made-up economy for learning, not real statistics. For official US figures, see the Bureau of Economic Analysis (bea.gov).
How to use the GDP calculator
- Choose whether your amounts are in millions, billions or trillions, and use that scale for every amount.
- Enter consumption, investment, government spending, exports and imports for one year. Investment may be negative if inventories fell sharply.
- Optionally add a GDP deflator to see real GDP, a population for GDP per person, and an earlier year's GDP to see the growth rate.
- The defaults are invented example figures. Replace them with data from an official source, such as a national statistics office, to study a real economy.
GDP formula (expenditure approach)
Real GDP = nominal GDP ÷ GDP deflator × 100
GDP per person = GDP ÷ population
Growth = (GDP this year ÷ GDP earlier − 1) × 100; average yearly growth = (later ÷ earlier)1/years − 1
C is household consumption, I is gross private investment (business equipment and buildings, new homes and changes in inventories), G is government consumption and investment, X is exports and M is imports. Imports are subtracted because they are already included in C, I and G but were produced abroad. Government transfers such as pensions are not in G, since they pay for no new production. The deflator is a price index for everything in GDP, equal to 100 in the base year, so dividing by it removes the effect of price changes.
Worked example (a made-up economy)
An imaginary country spends $700 billion on consumption, $180 billion on investment and $200 billion on government purchases. It exports $120 billion and imports $150 billion, so net exports are −$30 billion. GDP is 700 + 180 + 200 + (120 − 150) = $1,050 billion, of which consumption is 66.7%.
With a GDP deflator of 105, prices are 5% above the base year, so real GDP is $1,050 billion ÷ 105 × 100 = $1,000 billion. With 30 million people, GDP per person is $35,000. If GDP the year before was $950 billion, nominal GDP grew 10.53%; if that $950 billion was real GDP in the same base-year prices, real growth was 5.26%. These figures are invented for the arithmetic and describe no real country.
Nominal vs real GDP with different deflators
Illustrative: nominal GDP of $1,000 billion deflated at different price levels.
| GDP deflator | Prices vs base year | Real GDP |
|---|---|---|
| 90 | −10% | $1,111.11 billion |
| 95 | −5% | $1,052.63 billion |
| 100 | 0% | $1,000 billion |
| 105 | 5% | $952.38 billion |
| 110 | 10% | $909.09 billion |
| 120 | 20% | $833.33 billion |
Total and average yearly growth
| From | To | Years | Total growth | Average a year |
|---|---|---|---|---|
| $1,000 billion | $1,100 billion | 1 | 10% | 10% |
| $1,000 billion | $1,100 billion | 5 | 10% | 1.92% |
| $1,000 billion | $1,500 billion | 10 | 50% | 4.14% |
| $1,000 billion | $2,000 billion | 10 | 100% | 7.18% |
| $1,000 billion | $2,000 billion | 20 | 100% | 3.53% |
Things to keep in mind
- Other ways to measure GDP. Statisticians also add up incomes (wages, profits, rents) or the value added by each industry. In principle all three approaches give the same total; in practice there is a small statistical discrepancy.
- Compare real figures over time. Nominal GDP can rise just because prices rose. Real GDP shows how much more was actually produced.
- Per person, not just in total. A country can grow because its population grows. GDP per person is a better guide to average living standards, though it says nothing about how income is shared.
- Use official data for real economies. For the United States, the Bureau of Economic Analysis (bea.gov) publishes GDP and its components in the National Income and Product Accounts. Other countries publish theirs through national statistics offices.
To see how price changes affect money over time, try the inflation calculator. For growth rates of any value, the percentage calculator and ROI calculator use the same arithmetic.
Frequently asked questions
How do you calculate GDP?
With the expenditure approach, add consumption (C), investment (I), government spending (G) and net exports (exports minus imports). For a made-up economy with C = 700, I = 180, G = 200, X = 120 and M = 150 (billions), GDP is 700 + 180 + 200 − 30 = 1,050 billion.
Why are imports subtracted in the GDP formula?
GDP counts what is produced in the country. Spending on imported goods is already included in consumption, investment and government spending, so imports are subtracted to remove production that happened abroad.
How do you calculate real GDP?
Divide nominal GDP by the GDP deflator and multiply by 100. Nominal GDP of 1,050 billion with a deflator of 105 is real GDP of 1,000 billion in base-year prices.
How do you calculate GDP per capita?
Divide GDP by the population, using the same scale. 1,050 billion divided by 30 million people is 35,000 per person.
How do you calculate the GDP growth rate?
Divide this year’s GDP by last year’s, subtract 1 and multiply by 100. Going from 950 to 1,050 is 10.53% growth. Use real GDP for both years to measure growth in output rather than prices; over several years, the average yearly rate is (later ÷ earlier)^(1/years) − 1.