To subtract in Google Sheets, click an empty cell, type an equals sign, the cell you’re subtracting from, a minus sign and the cell you’re taking away, for example =A2-B2, then press Enter. The answer shows in the cell, and it updates on its own if either number changes. These steps cover Google Sheets in a web browser on Windows, Mac and ChromeOS, with a short section for the Sheets app on Android and iPhone.
A few terms before you start
You only need a Google account and a spreadsheet you can edit. If the file was shared with you as “view only,” you can’t type formulas into it, so ask the owner for edit access or make your own copy with File > Make a copy.
These words come up throughout the article:
- Formula: anything you type into a cell that starts with
=. Without the equals sign, Sheets treats what you type as plain text. - Minuend: the number you subtract from (the first number).
- Subtrahend: the number you take away (the second number).
- Cell reference: a column letter plus a row number, such as
B4, that points to the value in that cell. - Formula bar: the long box above the column letters. It shows the formula behind the selected cell, while the cell itself shows the result.
- Fill handle: the small blue square at the bottom-right corner of a selected cell. Dragging it copies a formula into neighboring cells.
Subtract one cell from another with the minus sign
The minus sign (the hyphen key, -) is the quickest and most flexible way to subtract, and it’s the method most people should use by default. Here’s how to subtract the value in B2 from the value in A2.
- Open your spreadsheet in Google Sheets and click the empty cell where you want the answer, such as C2.
- Type
=. Sheets now knows you’re entering a formula. - Click cell A2 (or type
A2). The reference appears in your formula and A2 gets a colored outline. - Type
-. - Click cell B2 (or type
B2). The formula now reads=A2-B2. - Press Enter (Return on a Mac). The cell shows the difference, and clicking it again shows the formula in the formula bar.
Spaces don’t matter, so =A2 - B2 works the same way. The order does matter: =A2-B2 and =B2-A2 give results with opposite signs.
Subtract typed numbers instead of cells
You can also type the numbers straight into the formula, like =250-75, which returns 175. This is handy for a quick one-off answer, but the result never changes unless you edit the formula. If the numbers already live in cells, point to the cells so the answer stays current.
Mixing the two is fine as well. =A2-20 subtracts a fixed 20 from whatever sits in A2.
Use the MINUS function instead
Google Sheets also has a built-in subtraction function. Its syntax is MINUS(value1, value2), where value1 is the number you subtract from and value2 is the number you take away. The MINUS function reference describes it as the equivalent of the - operator, so =MINUS(A2,B2) gives exactly the same answer as =A2-B2.
- Click the cell where you want the answer.
- Type
=MINUS(. A help box opens below the cell with the syntax and an example. - Click the first cell, type a comma, then click the second cell.
- Type
)and press Enter.
MINUS takes exactly two values, so it can’t subtract a whole list in one go. Choose it when you like seeing a named function in your formulas or when you’re nesting subtraction inside another function. For everything else, the minus sign is shorter. There’s a fuller walkthrough of the function, including where it trips people up, in this explanation of the MINUS function in Google Sheets.
Take several values away from one number
Say B1 holds a starting balance and B2 through B7 hold expenses. You have two good options.
Chain the minus signs. =B1-B2-B3-B4-B5-B6-B7 works left to right, subtracting each cell from the running total. It’s easy to read with three or four cells and tedious beyond that.
Add up the expenses first, then subtract the total. =B1-SUM(B2:B7) adds B2 through B7 with SUM and takes that total away from B1. Both formulas give the same answer, but the SUM version is shorter, and if you insert a new row inside the B2:B7 range, Sheets usually expands the range for you.
A third form, =SUM(B1,-B2,-B3), puts a minus sign in front of each value you want to remove. It works, but it’s harder to scan, so most people stick with one of the first two.
To compare the totals of two whole columns, subtract one SUM from another: =SUM(B2:B50)-SUM(C2:C50).
Subtract one column from another
When you have a column of starting values and a column of amounts to take away, write the formula once and copy it down.
- In C2, type
=A2-B2and press Enter. - Click C2 again so the blue fill handle appears at its bottom-right corner.
- Drag the fill handle down to the last row of data. Each copy adjusts its row number, so C3 becomes
=A3-B3, C4 becomes=A4-B4, and so on.
Keyboard alternatives help with long columns. Select C2 along with the empty cells below it and press Ctrl + D (⌘ + D on a Mac) to fill down. Or select the whole target range, type the formula once, and press Ctrl + Enter (⌘ + Enter on a Mac) to fill every selected cell. Both shortcuts are listed in the Google Sheets keyboard shortcuts.
One formula for the whole column with ARRAYFORMULA
If you’d rather not copy anything, ARRAYFORMULA can return a result for every row from a single cell:
=ARRAYFORMULA(A2:A20-B2:B20)
Type it in C2 and the differences spill down to C20. Both ranges must be the same size, and the cells below the formula need to be empty, or Sheets can’t place the results. Pressing Ctrl + Shift + Enter (⌘ + Shift + Enter on a Mac) while you’re editing a formula adds ARRAYFORMULA( to the start for you, as noted on the ARRAYFORMULA help page. The same idea works across rows, for example =ARRAYFORMULA(B1:E1-B2:E2), and for two blocks of equal shape, such as =ARRAYFORMULA(A2:C4-E2:G4).
Which should you pick? Copied formulas are easier for other people to understand and edit one row at a time. ARRAYFORMULA keeps the sheet tidy when rows get added often, because one formula covers them all.
Subtract the same number from every row
Suppose E1 holds a flat fee that should come off every value in column A. If you type =A2-E1 and drag it down, the next row becomes =A3-E2, which points at the wrong cell. Lock the fee cell with dollar signs instead:
=A2-$E$1
Now A2 moves as you fill down, while $E$1 stays fixed. You don’t have to type the dollar signs: while entering the formula, put the cursor on the reference and press F4 on Windows, Fn + F4 on a Mac, or Search + 4 on a Chromebook to cycle through the locked and unlocked versions. $E1 locks only the column and E$1 locks only the row.
Subtract values that sit on different tabs
To use a cell from another sheet in the same file, type the sheet name, an exclamation point and the cell. For example, =Sheet1!B5-Sheet2!B5 subtracts B5 on Sheet2 from B5 on Sheet1. If a sheet name contains spaces or symbols, wrap it in single quotes, like ='March Sales'!B5-'March Costs'!B5. Google explains the rule in referencing data from other sheets. You can also click over to the other tab while typing the formula and Sheets fills in the reference.
Dates, times and percentages
The same minus sign handles more than plain numbers:
- Dates:
=B2-A2, with the later date in B2, returns the number of days between them. The DAYS function,=DAYS(B2,A2), does the same with the end date first. Add+1if both the first and last day should count. Months, years and workdays need other functions, covered in subtracting dates in Google Sheets. - Times: subtracting a start time from an end time gives the elapsed time, and
=A2-TIME(1,30,0)takes 1 hour 30 minutes off the time in A2. Format the result as a duration so it reads correctly. Overnight shifts and totals past 24 hours have their own quirks, explained in how to subtract time in Google Sheets. - Percentages: to remove a percentage of a value, multiply rather than subtract the percentage itself.
=A2*(1-15%)or=A2-A2*15%both take 15% off A2. Typing=A2-15%subtracts 0.15, which is rarely what you want.
In the Google Sheets app on Android or iPhone
Formulas behave the same in the mobile app; only the typing is different. Open the spreadsheet, double-tap the cell where you want the answer, type the formula (for example =A2-B2) in the edit box that appears, then tap Done to save it. On many phone keyboards the minus sign and the equals sign sit on the numbers and symbols layout, and the app also shows a row of symbols below the edit box. Type cell names such as A2 into the formula to refer to other cells.
Worked example: a shared trip budget
Alex, Jordan and Priya each set aside money for a weekend trip and logged what they spent. Column B holds each person’s budget, column C holds spending, and column D should show what’s left.
| A | B | C | D | |
|---|---|---|---|---|
| 1 | Name | Budget | Spent | Left |
| 2 | Alex | 400 | 285 | =B2-C2 shows 115 |
| 3 | Jordan | 350 | 390 | =B3-C3 shows -40 |
| 4 | Priya | 500 | 310 | =B4-C4 shows 190 |
| 5 | Total | =SUM(B2:B4) shows 1250 | =SUM(C2:C4) shows 985 | =B5-C5 shows 265 |
To build it, type =B2-C2 in D2 and drag the fill handle down to D4. Jordan’s -40 isn’t an error: it means he went 40 over budget. The total in D5 can be checked two ways. =B5-C5 subtracts total spending from the total budget, and adding the individual results (115 – 40 + 190) also gives 265. When two routes land on the same number, the formulas are almost certainly right.
If the group also paid a shared 30 parking fee stored in F1, =B2-C2-$F$1 in D2, filled down, would take the same 30 off everyone.
When the answer looks wrong
Most subtraction problems come from a handful of causes. Work through these before rewriting anything.
- The formula shows as text. If the cell displays
A2-B2instead of a number, the equals sign is missing, or there’s a space or apostrophe in front of it. Edit the cell so it starts with=. - #VALUE! One of the cells holds text that can’t be read as a number, such as “n/a” or a number with a stray letter. In most cases, hovering over the cell shows a short explanation. Fix or clear the offending cell.
- #REF! A cell or sheet the formula pointed to was deleted. Retype the reference, or press Ctrl + Z (⌘ + Z on a Mac) right away to bring the deleted cells back.
- #NAME? Sheets doesn’t recognize a function name. There’s no SUBTRACT function, for example, so
=SUBTRACT(A2,B2)fails. Use MINUS or the minus sign. - The sign is backwards. A negative result where you expected a positive one usually means the cells are in the wrong order. Swap them, or wrap the formula in ABS, like
=ABS(A2-B2), when you only care about the size of the gap. - Mixed math gives an odd total. Sheets multiplies and divides before it adds and subtracts.
=100-20*2returns 60, while=(100-20)*2returns 160. Use parentheses to make the subtraction happen first. - The result looks like a date or has too many decimals. That’s formatting, not math. Select the cell and choose Format > Number, then pick the format you want. The number formatting help page also shows how to build custom formats, such as showing negatives in red.
- Copied formulas point to the wrong cell. A reference that should stay put needs dollar signs, as shown in the fixed-number section above.
If some rows are expected to have gaps or bad data, =IFERROR(A2-B2,"") shows a blank cell instead of an error. Use it sparingly, because it also hides problems you’d want to know about.
A word of caution before you overwrite anything: typing a formula into a cell replaces whatever was there. Check that the target cell is empty, especially before an ARRAYFORMULA that will spill down a whole column.
Check the result and undo mistakes
Click the answer cell and look at the formula bar. Sheets outlines every referenced cell in a matching color, so you can confirm at a glance that the formula points where you meant. To review a whole sheet at once, press Ctrl + ~ (the same keys on Mac) to show all formulas instead of results, then press it again to switch back.
For a quick sanity check, select the cells you’re comparing and look at the bottom-right corner of the window, where Sheets shows a summary such as the sum of the selection. You can also do one row by hand and make sure it matches.
To reverse a mistake, press Ctrl + Z (⌘ + Z on a Mac), or open Edit > Undo. If you notice the problem much later, version history lets you see and restore an earlier version of the whole file; Google’s help on finding what’s changed in a file shows where to open it.
Other things people ask about subtracting in Sheets
Is there a SUBTRACT function?
No. The Google Sheets function list includes MINUS, which subtracts two values, and UMINUS, which flips a number’s sign, but nothing called SUBTRACT.
Can I subtract a range of cells with MINUS?
Not directly, because MINUS expects two single values. Total the range with SUM and subtract that, as in =A1-SUM(A2:A10), or use the minus sign inside ARRAYFORMULA for row-by-row results.
How do I add and subtract in the same formula?
Just combine the operators: =A2+B2-C2. Addition and subtraction run left to right, so add parentheses only when you need a different order.
Can I subtract fractions?
Yes. =3/4-1/3 returns about 0.4167. Sheets shows the answer as a decimal unless you apply a fraction format with Format > Number > Custom number format, such as # ?/?.
Will these formulas work if I open the file in Excel?
Basic formulas built with the minus sign, SUM and dollar-sign references are written the same way in Excel. Google-specific functions are the ones to double-check after the move, and if you’ll be doing more work there, see subtraction formulas in Excel.
Where to go from here
Start with =A2-B2 and the fill handle; that covers most everyday subtraction. When the sheet grows, switch to SUM for long lists, dollar signs for fixed values and ARRAYFORMULA for columns that keep getting new rows. Try the trip budget table above in a blank sheet to see each method in action.