How to build a quote calculator in Google Sheets
A quote goes wrong in small ways. Someone types last year's price from memory, forgets the wholesale discount, or works out tax on the wrong figure. A quote calculator removes the typing: you choose a product and a quantity, and the sheet works out the rest from one price list and one set of rates.
The example is a shop selling mugs and plates, with no currency assumed. The 18% tax rate is only an example, so use your own.
Put the rates on a Settings tab
Add a tab called Settings. Type Setting in A1 and Value in B1, then:
| Row | Setting | Value |
|---|---|---|
| 2 | Tax rate | 18% |
| 3 | Wholesale discount | 15% |
| 4 | Retail discount | 0% |
| 5 | Bulk quantity threshold | 50 |
| 6 | Extra bulk discount | 5% |
Type each rate with its percent sign. Every formula below reads these cells, so when the tax rate changes you change B2 and nothing else.
Keep every price on a Price list tab
Add a tab called Price list with SKU in column A, Product in B and Unit price in C:
| SKU | Product | Unit price |
|---|---|---|
| M-101 | Blue mug | 299 |
| M-103 | Speckled mug | 349 |
| P-201 | Dinner plate | 449 |
| T-401 | Teapot | 999 |
One row per product, and no SKU twice. If a SKU appears twice, the lookup uses the first one it finds and ignores the other.
Set up the Quotes tab
Add a tab called Quotes with these headers in row 1:
| A | B | C | D | E | F | G | H | I | J | K | L | M |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Quote ID | Date | Customer | Customer type | SKU | Quantity | Product | Unit price | Discount | Subtotal | Tax | Total | Status |
Columns A to F and M are typed. Columns G to L are formulas. Three of the typed columns should be dropdowns, so a spelling slip cannot break a formula:
- Select D2 down to D200 and choose Data > Data validation > Add rule.
- Under Criteria pick Dropdown and enter Retail and Wholesale. Click Done.
- Do the same for M2:M200 with Draft, Sent, Won and Lost.
- For E2:E200, pick Dropdown from a range and enter
'Price list'!A2:A.
Google's page on dropdown lists says an entry that is not on the list is rejected unless you choose to show a warning instead. Our guide to a dropdown for order status covers the options in more detail.
Add the six formulas
Put these in row 2, in G2 to L2:
Product =IF(E2="", "", XLOOKUP(E2, 'Price list'!A:A, 'Price list'!B:B, "SKU not found"))
Unit price =IF(E2="", "", XLOOKUP(E2, 'Price list'!A:A, 'Price list'!C:C))
Discount =IF(E2="", "", IF(D2="Wholesale", Settings!$B$3, Settings!$B$4) + IF(F2>=Settings!$B$5, Settings!$B$6, 0))
Subtotal =IF(E2="", "", ROUND(F2*H2*(1-I2), 2))
Tax =IF(E2="", "", ROUND(J2*Settings!$B$2, 2))
Total =IF(E2="", "", J2+K2)
Select G2 to L2 and fill them down to row 200. The IF(E2="", "", ...) part keeps a row blank until a SKU is chosen.
- XLOOKUP finds the SKU in column A of the price list and returns the cell from the same row of another column. The fourth part is what to show when there is no match. Unit price leaves it out on purpose. Google's page says the result is then
#N/A, and that error carries into Subtotal, Tax and Total. A quote with no price should look broken. - Discount picks the wholesale or retail rate, then adds the bulk rate if the quantity reaches the threshold. The
$signs stop the Settings cells from shifting as you fill down. - Subtotal is quantity times price, less the discount.
- Tax is charged on the subtotal, after the discount. If your rules tax the full price, change this formula.
- ROUND with
2keeps money to two decimal places. Without it a cell can show 12.35 while holding 12.345, and a column of quotes will not add up to what is on screen.
Check it against four quotes
Type columns A to F and the status, and the rest should appear:
| Quote ID | Customer | Type | SKU | Qty | Unit price | Discount | Subtotal | Tax | Total | Status |
|---|---|---|---|---|---|---|---|---|---|---|
| Q-2001 | Cafe Lotus | Wholesale | P-201 | 60 | 449 | 20% | 21,552.00 | 3,879.36 | 25,431.36 | Won |
| Q-2002 | Meena Home | Retail | T-401 | 2 | 999 | 0% | 1,998.00 | 359.64 | 2,357.64 | Won |
| Q-2003 | Sri Stores | Wholesale | M-101 | 40 | 299 | 15% | 10,166.00 | 1,829.88 | 11,995.88 | Sent |
| Q-2004 | Kiran & Co | Retail | M-103 | 60 | 349 | 5% | 19,893.00 | 3,580.74 | 23,473.74 | Sent |
Work one through by hand. Q-2001 is 60 plates at 449, which is 26,940. Cafe Lotus is wholesale (15%) and 60 is over the threshold of 50 (5% more), so 20% comes off: 26,940 less 5,388 is 21,552. Tax at 18% is 3,879.36, and the total is 25,431.36.
The other three test the other paths: retail with no discount, wholesale under the threshold, and retail over it. If all four match, the Discount formula is right.
To see what is still waiting on customers, put =SUMIFS(Quotes!L:L, Quotes!M:M, "Sent") in a free cell away from the table. Here it gives 11,995.88 + 23,473.74 = 35,469.62.
Freeze a quote once you have sent it
This is the catch with any quote sheet built on lookups. Every quote reads the price list live, including the ones you sent last month.
Raise the dinner plate from 449 to 479 and Q-2001, which Cafe Lotus has already accepted at 25,431.36, quietly becomes 27,130.56. Change the tax rate in Settings and every quote on the tab moves.
So when a quote's status changes to Sent, fix its numbers:
- Select G to L on that quote's row and copy.
- With the same cells selected, choose Edit > Paste special and pick the values-only option. Google's page on copy and paste says it pastes only the text from the copied cells.
The row now holds plain numbers that no later price change can touch. If the customer asks for a revision, copy the formulas back from an unused row below.
Stop the formulas being typed over
Columns G to L should never be typed in, except by the freeze step above. Select them, choose Data > Protect sheets and ranges, and pick Show a warning when editing this range. Google's page on protecting ranges also covers the stricter option that limits who can edit. Our guide to stopping people overwriting each other goes further.
Fix a quote that looks wrong
- Unit price shows #N/A. The SKU is not on the price list, or one copy has a space after it. Pick it from the dropdown.
- A wholesale customer got the retail rate. Customer type holds something other than the word Wholesale, often with a stray space. The dropdown prevents this.
- Tax is far too large. A rate was typed as 18 without the percent sign, which is 1,800%.
Where BoltSheets fits
Everything above works in a plain Google Sheet. The BoltSheets quote calculator template has the same three tabs and the same discount rule, and adds a Unit cost column on the price list and a Margin column on each quote. It looks prices up with INDEX and MATCH and does not round, and its quotes recalculate when a price changes, so the freeze step still applies and is yours to do. In the demo you can ask for a quote to be created or a price to be changed in words. The change is shown as a preview and written only when a person confirms it, and formula cells are never written to. BoltSheets is in early access and works with Google Sheets only. The template opens as a demo for now and is not yet a sheet you can copy.
Common questions
How do I quote several products on one quote?
Use one row per product and give every row of the quote the same Quote ID. Each row works out its own line total. For the quote total, add the rows that share the ID, for example =SUMIF(Quotes!A:A, "Q-2005", Quotes!L:L).
Should two discounts be added together or applied one after the other?
Decide once and keep to it, because the results differ. Adding 15% and 5% gives 20% off. Applying 15% and then 5% to what is left gives 19.25% off, since 0.85 times 0.95 is 0.8075. The formula in this guide adds them.
How do I give one customer a discount that is not in Settings?
Add a typed column called Extra discount after Status, in column N, and add + N2 inside the Discount formula, just before its last bracket. An empty cell counts as zero, so most rows are unchanged. Type 3% on the one quote that needs it.
Why does my discount show as 0.2 and not 20%?
The value is right and only the display differs. Select the Discount column, choose Format, then Number, and pick the percent format. 0.2 and 20% are the same number to a formula.