VAT, GST and sales tax calculator
Type a price and a tax rate to add the tax on top, or to split the tax out of a price that already includes it. If you only know the two prices, it finds the rate. For an invoice with several rates, enter one line per item and read the totals per rate. You enter the rate yourself: this page does not know any country's rates. Everything is worked out in your browser and nothing is sent anywhere.
Settings used by all three calculators
Shown in front of amounts, up to 4 characters. It changes nothing in the arithmetic. Leave it empty for plain numbers.
2 for most currencies (cents), 0 for yen or won, 3 for dinar. Amounts you type can have at most this many decimals.
Type 1.5 or 1,5; a lone 1,234 is ambiguous (1.234 or 1234?), so it is not guessed. A rate of 20 and 20% both mean 20 percent. Negative amounts (credit notes) are fine, negative rates are not.
This is a calculator, not tax advice. It does not know your tax rates, and the legal rounding rules differ by country: some require tax rounded on each invoice line, some on the invoice total, some per rate. Check what applies to your invoices.
Add tax to a price, or take it out
One price and one rate. For example 100 at 20%.
Quick picks (plain numbers, not official rates)
The quick-pick buttons are plain numbers, not official rates. Rates change and differ by country, region and type of goods, so check your local tax authority.
- Before tax
- 100.00
- Tax
- 20.00
- Including tax
- 120.00
100.00 plus 20% tax is 120.00. The tax is 20.00.
Formula
Tax = Price × Rate ÷ 100, then Price + Tax
- 1. 100.00 × 20 ÷ 100 = 20 (tax before rounding)
- 2. Rounded to 2 decimals: 20.00
- 3. 100.00 + 20.00 = 120.00
The tax came out exact, nothing was rounded.
Find the tax rate from two prices
You know the price before tax and the price including tax. For example 100 and 120.
- Tax rate
- 20%
Going from 100 to 120 adds 20, which is a tax rate of 20%.
Rate = (Including − Before) ÷ Before × 100
Prices are themselves rounded. If both were rounded to 2 decimals, the real rate could be anywhere from 19.989% to 20.011%.
A round-looking result is a hint, not proof: the rate that was used might be a nearby one.
Several lines with different rates
An invoice or receipt: one line per item, each with its own rate. Totals are shown per rate and overall.
The three methods can differ by a unit or two in the last decimal. The table “Same lines, every method” shows the effect for your numbers.
- Before tax
- 38.34
- Tax
- 5.83
- Including tax
- 44.17
Before tax 38.34, tax 5.83, including tax 44.17.
Totals by tax rate (each line rounded)
| Rate | Lines | Before tax | Tax | Including tax |
|---|---|---|---|---|
| 5% | 1 | 9.99 | 0.50 | 10.49 |
| 10% | 3 | 3.36 | 0.33 | 3.69 |
| 20% | 1 | 24.99 | 5.00 | 29.99 |
| Total | 5 | 38.34 | 5.83 | 44.17 |
Lines
The per-line figures below are each line rounded on its own, the way an itemised invoice shows them. Totals above use the method you chose.
| Line | Rate | Before tax | Tax | Including tax |
|---|---|---|---|---|
| 1 | 10% | 1.12 | 0.11 | 1.23 |
| 2 | 10% | 1.12 | 0.11 | 1.23 |
| 3 | 10% | 1.12 | 0.11 | 1.23 |
| 4 | 20% | 24.99 | 5.00 | 29.99 |
| 5 | 5% | 9.99 | 0.50 | 10.49 |
Same lines, every method
Total tax for exactly your lines under each method and tie rule. It is the same arithmetic, only the rounding differs.
| Method | Half up | Half to even |
|---|---|---|
| Round each line, then add the lines | 5.83 | 5.83 |
| Add the lines at each rate, round once per rate | 5.84 | 5.84 |
| Add every line, round the total once | 5.83 | 5.83 |
Tax before any rounding: 5.8335. The tax shown differs from it by -0.0035.
On these lines the choice of rounding moves the total tax by up to 0.01.
How it works
- •Add tax: tax = price × rate ÷ 100, and the price including tax is price + tax. Take tax out: tax = price × rate ÷ (100 + rate), and the price before tax is price − tax. Dividing by (100 + rate) is what makes the two directions match; subtracting the rate from the larger price does not.
- •Amounts and rates are read as exact decimals and calculated with whole numbers, so there is no floating-point noise. Type 12.5 or 12,5. Amounts can have at most as many decimals as the currency (you choose 0 to 4), rates can have any number of decimals.
- •The tax is rounded to the currency's decimals. You choose how: round each line and add them, round once per rate, or add everything and round the total once; and whether an exact half goes up (0.125 becomes 0.13) or to the even digit (0.125 becomes 0.12).
- •The multi-line calculator shows the totals by rate and, next to them, the same lines under all three methods and both tie rules, with the difference from the unrounded tax, so you can see how much the choice matters for your numbers.
- •The currency symbol is only drawn in front of the amounts. It changes nothing in the arithmetic. This is a calculator, not tax advice, and the legal rounding rules differ by country, so check what applies to your invoices.
Questions
- Why can I not just take the rate off a price that includes tax?
- Because the tax was added on top of the smaller, before-tax price, so it is not 20% of the larger, tax-inclusive price. A price of 100 that includes 20% tax contains 100 × 20 ÷ 120 = 16.67 of tax, so it is 83.33 before tax, not 80. The page divides by (100 + rate) ÷ 100 and shows the steps.
- Why do the total and the sum of the lines differ by a cent?
- Each line's tax is rarely a whole number of cents, and rounding every line separately is not the same as rounding the total once. Three lines of 1.12 at 10% each have 0.112 of tax, which rounds to 0.11 per line and 0.33 in all, while the exact total is 0.336, which rounds to 0.34. The multi-line calculator shows both and says which one you picked.
- Which rounding rule should I use, and which tax rates apply to me?
- That depends on your country and sometimes on the kind of invoice, and this page does not know. Some systems want tax rounded line by line, some on the invoice total, some per rate, and a few use half-to-even. Rates change and differ by goods, so the quick-pick buttons are only plain numbers. Check your tax authority or your accountant; this is a calculator, not tax advice.
- Is anything uploaded, and how big can the numbers be?
- Nothing leaves your browser; there are no requests, no cookies and nothing is stored, and reloading the page resets the boxes. Numbers are exact whole-number arithmetic, so amounts of 30 digits or more work without losing the last cent. A single box accepts up to 60 characters and the table up to 50 lines.