To subtract in Google Sheets, click an empty cell, type an equals sign and the cells with a minus sign between them, such as =A2-B2, then press Enter. The cell shows the difference and updates whenever A2 or B2 changes. For exactly two values, =MINUS(A2,B2) gives the same result. These steps work in Google Sheets on the web and in the Sheets app for Android, iPhone and iPad.
A few terms before you start
- Formula: anything you type into a cell that starts with =. Without the equals sign, Sheets treats “A2-B2” as plain text.
- Cell reference: a column letter plus a row number, like B2. Using references instead of typed numbers means the result recalculates when the data changes.
- Minuend and subtrahend: the number you start with and the number you take away. In =A2-B2, A2 is the minuend and B2 the subtrahend, so order matters: =B2-A2 gives the same size of answer with the opposite sign.
Subtract one cell from another
Say Jordan tracks a monthly budget with Income in column A and Expenses in column B, starting in row 2, and wants what’s left in column C.
- Click cell C2, where the result should appear.
- Type =. The cell and the formula bar above the grid both show the equals sign.
- Click cell A2 (or type A2). A colored outline appears around it.
- Type a minus sign – (the hyphen key, or the minus key on the number pad).
- Click cell B2. The formula now reads =A2-B2.
- Press Enter. C2 shows the difference; with 3,200 in A2 and 2,450 in B2, it shows 750. Click C2 again and the formula bar shows the formula behind the number.
You can also subtract typed numbers (=1200-375) or mix the two (=A2-50), but references are easier to maintain: change a value in column A or B and every result that depends on it updates.
Copy the formula down a whole column
You only write the formula once. To repeat it for every row:
- Click C2, the cell with your formula.
- Point to the small blue square at the bottom right corner of the cell (the fill handle) until the pointer becomes a crosshair.
- Drag down to the last row of data and let go. Each row gets its own version: C3 becomes =A3-B3, C4 becomes =A4-B4, and so on.
For a long list, select C2 down to the last row and press Ctrl + D (⌘ + D on a Mac), which Google’s Google Sheets keyboard shortcuts list describes as copying the top cell’s contents into the cells below. Double-clicking the fill handle often fills down automatically when the column next to it has data, which saves dragging past hundreds of rows.
Use the MINUS function
Google’s MINUS function reference describes it as returning the difference of two numbers, equivalent to the – operator. The syntax is MINUS(value1, value2), where value1 is the number to subtract from and value2 is the number to take away.
- =MINUS(A2,B2) gives the same answer as =A2-B2.
- =MINUS(10,4) returns 6.
MINUS takes exactly two values, so it can’t subtract a range like B2:D2. Most people stick with the minus sign because it’s shorter and handles any number of values; MINUS is handy when you’re building formulas from the function list or teaching someone the order of the two arguments.
Subtract several cells or a whole range
There are two ways to take more than one value away from a starting number:
- Chain minus signs: =A2-B2-C2-D2. Fine for a few cells.
- Subtract a SUM: =A2-SUM(B2:D2). SUM adds the range first, then the total is taken from A2. This is easier to read, and adding a column inside the range is picked up automatically.
Both give the same answer. Watch the parentheses if you write it out by hand: =A2-B2+C2 adds C2 back, while =A2-(B2+C2) subtracts both.
To subtract a whole column from a single number, for example a starting balance in B1 minus every expense in B3:B20, use =B1-SUM(B3:B20).
Subtract the same number from every row
When every row needs the same value taken off, such as a $15 shipping credit stored in cell F1, the reference to F1 must not move as you copy the formula down. Lock it with dollar signs:
- In C2, type =A2-$F$1. While typing a reference, you can press F4 (Fn + F4 on a Mac, or Search + 4 on a Chromebook) to cycle through the locked versions, as Google’s shortcut list notes.
- Press Enter, then fill the formula down.
A2 changes to A3, A4 and so on, but $F$1 stays fixed. Without the dollar signs, the copies would point to F2, F3 and other empty cells, and the results would quietly equal column A.
Subtract percentages
To reduce a value by a percentage, multiply by one minus the percentage rather than subtracting the percentage directly:
- Price in A2, discount of 20% in B2: =A2*(1-B2). With 80 in A2, the result is 64.
- =A2-B2 here would give 79.8, because 20% is stored as 0.2.
- To find the difference between two percentages (say, 45% this year and 38% last year), plain subtraction is right: =A2-B2 returns 7% when the cell uses a percent format.
Subtract dates and times
Sheets stores dates as numbers, so subtracting one date from another returns the number of days between them.
- Put the earlier date in A2 and the later date in B2 (for example, an order date and a delivery date).
- In C2, type =B2-A2 and press Enter.
- If the result looks like a date instead of a number of days, select C2 and choose Format > Number, then a plain number format. Google’s DATEDIF page gives the same advice when a day count shows up as a date.
For months or years, use DATEDIF. According to Google’s DATEDIF help page, the syntax is DATEDIF(start_date, end_date, unit), and the units include “Y” (whole years), “M” (whole months), “D” (days), “YM” (months left after whole years) and “MD” (days left after whole months). For example, =DATEDIF(A2,TODAY(),”Y”) gives someone’s age in whole years from a birth date in A2. A month only counts once the end date reaches the same day of the month.
The DAYS function is another option: =DAYS(B2,A2) puts the end date first and counts leap days.
Times work the same way. With a start time of 9:00 AM in A2 and an end time of 5:30 PM in B2, =B2-A2 returns the gap, which Sheets displays as a time (8:30). Use Format > Number and pick a time or duration format if it shows a decimal instead. For shifts that cross midnight, include the date with each time so the end is later than the start.
Fix common subtraction problems
#VALUE! error
Usually one of the cells holds text instead of a number. Common culprits are numbers pasted with a currency symbol in an unusual spot, a stray space, or a number typed with an apostrophe in front. Click the cell and check the formula bar. Retype the number, or use Format > Number to apply a number format and re-enter the value.
The formula shows as text
If the cell displays “=A2-B2” instead of a result, the cell may be formatted as plain text, or there’s a space before the equals sign. Delete the space or change the format, then press Enter on the formula again.
#REF! error
Usually a cell the formula pointed to was deleted, for example when you removed column B. Rewrite the formula with the correct cells, or press Ctrl + Z (⌘ + Z) to undo the deletion.
The answer is negative when you expected positive
The cells are in the wrong order: =B2-A2 when you meant =A2-B2. Swap them, or wrap the formula in ABS, as in =ABS(A2-B2), if you only care about the size of the difference.
A tiny decimal instead of zero
Subtracting decimals can leave results like 0.0000000001 because of how computers store fractions. Use the toolbar’s decrease decimal places button to hide it, or wrap the formula in ROUND, as in =ROUND(A2-B2,2), to round to two decimal places.
Subtract in the Google Sheets app
- Open the spreadsheet in the Sheets app and tap the cell for the result.
- Type = in the text box that opens. Symbols such as the minus sign appear below the text box.
- Tap the first cell, type – on the keyboard, then tap the second cell.
- Tap Done to finish. The result appears in the cell.
To copy the formula down in the app, tap the cell, tap it again and choose Copy, select the cells below and paste. Big ranges are faster on a computer.
Make the result easy to read
A few touches help when you share the sheet: label column C (“Remaining” or “Difference”), apply a currency or number format with Format > Number, and add a thicker line above a total row. Here’s how to add borders in Google Sheets for that total. Google’s number format help also explains that a custom format can show negative results in a different color, such as [Red], which makes shortfalls stand out. If the sheet will be printed across several pages, you can repeat the header row on every page so readers always know which column is which.
Common questions about subtraction in Google Sheets
Is there a SUBTRACT function?
No. Google Sheets uses the minus sign or MINUS. Typing =SUBTRACT(A2,B2) gives an error because no function by that name exists.
Can I subtract a value on another tab?
Yes. Put the tab name before the cell with an exclamation mark: =A2-Expenses!B2. If the tab name has spaces, wrap it in single quotes, as in =A2-‘March Costs’!B2. Clicking the other tab while typing the formula inserts the reference for you.
Will the formula still work after I sort the data?
Yes, as long as you sort whole rows together. Each result moves with its row and keeps pointing at the cells in that row. Sorting just one column breaks the pairing, so select the whole table before sorting.
Try it on your own data now: add a “Difference” column next to two numbers you track, write the formula once in the first row and fill it down.
Matthew Burleigh has been a freelance writer since the early 2000s. You can find his writing all over the Web, where his content has collectively been read millions of times.
Matthew received his Master’s degree in Computer Science, then spent over a decade as an IT consultant for small businesses before focusing on writing and website creation.
The topics he covers for MasterYourTech.com include iPhones, Microsoft Office, and Google Apps.
You can read his full bio here.