How to Delete Cells in Excel Without Losing Formulas

Formulas & functions · Updated November 20, 2026

To remove entries without removing formulas in Excel, select only the cells containing the entries and choose Home > Clear > Clear Contents. If your selection includes both entries and formulas, use Go To Special to select constants only before clearing. This removes cell contents while leaving formulas in place; it does not delete or shift cells.

What You’ll Need

  • A Microsoft Excel workbook you can edit, preferably with a saved backup if the data is important.
  • A clear idea of which cells contain input data and which contain formulas. Click a cell and check the formula bar: a formula begins with an equals sign.
  • Optional: a mouse or keyboard access to Go To Special, which can select constant values without selecting formulas.

Step-by-Step

  1. Save a copy before making a large change. Choose File > Save As and save a separate copy, or save the workbook under a new name. This is especially useful when clearing a broad range, deleting rows, or working with a shared workbook. Ctrl+Z can undo many ordinary edits, but a backup is safer if you save, close, or make several changes afterward.
  2. Identify the formula cells and the cells you want to clear. Click a few cells in the area. A formula such as =SUM(B2:B10) appears in the formula bar, while a typed value appears as a value. If the formula bar is hidden, select View > Formula Bar. You can also press Ctrl+` on Windows to show formulas on the sheet; press the same shortcut again to return to normal view. On Mac, use Control+` if that key is available on your keyboard.
  3. If the target cells contain only inputs, select just those cells. Drag across the input range, click its first cell and Shift-click its last cell, or enter a range such as A2:B20 in the Name Box to the left of the formula bar. Check the selection before proceeding. Do not include a total row or calculated column merely because it is adjacent to the data.
  4. Clear the contents rather than deleting the cells. On Windows, choose Home > Clear > Clear Contents. You can also press the Delete key. On Mac, choose Home > Clear > Clear Contents; the keyboard key that clears contents may be labeled Delete or Backspace depending on the keyboard. Clear Contents removes values and formulas from the selected cells, but it preserves their formatting and does not move other cells. It is safe for formulas only when the selection excludes them.
  5. If the selection includes formulas, select constants only first. Click a cell in the relevant area, then choose Home > Find & Select > Go To Special on Windows. In the dialog, select Constants. Leave the value types checked if you want to clear all typed numbers, text, logical values, and errors; uncheck types you need to keep. Make sure Formulas is not selected, then click OK. Excel selects the matching constant cells in the current selection or worksheet, depending on what you selected before opening the dialog. Press Delete, or choose Home > Clear > Clear Contents.
  6. Use Go To Special carefully on a mixed or large sheet. Before opening Go To Special, select the specific table or range you intend to clean. If you start with only one cell selected, Excel may search the broader worksheet, which can select constants in unrelated areas. Inspect the highlighted cells before clearing. To select typed entries of only one kind, use the Constants options: for example, leave Text checked and clear the other checkboxes if you want to target text entries but keep numbers.
  7. Check the formulas after clearing. Click a formula cell and look at the formula bar to confirm that its formula remains. A formula may show a blank, zero, or an error after its input is cleared, depending on how it was written. For example, with quantity in A2 and unit price in B2, put this formula in C2: =IF(A2="","",A2*B2). If A2 is blank, C2 displays blank; if A2 contains 3 and B2 contains 12, C2 returns 36. Clearing A2 does not remove the formula in C2.
  8. If you mean remove a whole row, decide whether shifting is intended. Right-click the row number and choose Delete to remove the row and shift the rows below upward. This is different from Clear Contents. Excel adjusts many references when cells or rows are deleted, but the result may not match your goal, especially in complex formulas, charts, named ranges, or external links. If you want to retain the layout and formulas, clear only the input cells in that row instead.
  9. For a sheet that is edited repeatedly, protect the formula cells. First select the cells people are allowed to edit. Press Ctrl+1, open the Protection tab, clear Locked, and click OK. Then choose Review > Protect Sheet and set the permissions you want. By default, cells are marked locked, but that setting only prevents editing after sheet protection is turned on. With protection enabled, users can edit the unlocked input cells while formula cells remain protected. Keep the password somewhere safe if you set one.

Common Mistakes

Pressing Delete after selecting too much. The Delete key clears the contents of every selected cell, including formulas. If a formula is inside the selection, it will be removed just like a typed value. Undo immediately with Ctrl+Z on Windows or Command+Z on Mac if you notice the mistake, then make a narrower selection.

Choosing Delete instead of Clear Contents. The Delete command for a cell, row, or column can shift neighboring cells or change the worksheet structure. Clear Contents is the appropriate choice when you want the cells to remain where they are, with their formatting intact. Use a structural delete only when you truly want to remove cells and shift others.

Assuming a blank-looking cell is empty. A formula can return an empty string and appear blank while still containing a formula. Go To Special treats that cell as a formula, not as an empty cell. Conversely, a cell with a space character is a constant, even if it looks empty. Check the formula bar before clearing uncertain cells.

Clearing an entire table column without checking calculated cells. Excel tables may fill a calculated column with a formula for each row. Selecting the whole column and clearing it can remove those formulas. Select only the input column, or use Go To Special on a precisely selected range and review the result.

Expecting a formula to keep showing its old answer. When you clear an input used by a formula, the formula recalculates. That is normal: preserving the formula does not preserve its previous result. If the output should look blank until inputs are provided, adjust the formula’s logic rather than deleting the formula.

Tips

  • Use a consistent layout: input cells in one area or color, formulas in another. Color is a visual cue, not proof; verify formulas in the formula bar before clearing.
  • For repeated data entry, protect the worksheet and unlock only the input cells. This reduces accidental formula deletion, although protection is not a substitute for a backup.
  • When clearing values from a filtered list, check which rows are visible and whether hidden rows are included in your selection. If you need to affect visible cells only, use Go To Special > Visible cells only before clearing, then inspect the highlighted selection.
  • If you want to remove values but keep formatting, use Clear Contents rather than Home > Clear > Clear All. Clear All also removes formatting and other cell attributes.
  • For a single cell, replacing its contents with a blank is not the same as deleting the cell. Avoid typing a space to make a cell look empty; the space remains data and can affect sorting, filtering, and formulas.
  • In a shared workbook, confirm that you have permission to edit and that another person is not changing the same range. If a protected sheet blocks the operation, ask the owner for the password or an editable copy rather than trying to work around protection.

Troubleshooting

The formula disappeared. If the cell now looks empty and its formula bar is also empty, the formula was likely included in the cleared selection. Press Ctrl+Z on Windows or Command+Z on Mac immediately. If undo is unavailable, restore the formula from a backup, a neighboring row, or the workbook’s version history if it is stored in OneDrive or SharePoint. Check the references carefully before copying a formula from another row.

Go To Special selected the wrong cells. Press Escape without clearing, or click another cell to cancel the selection. Reselect the intended range first, reopen Home > Find & Select > Go To Special, and choose Constants. If only one category of value should be cleared, adjust the Numbers, Text, Logicals, and Errors checkboxes. Review the selection before pressing Delete.

The output changed or displays an error. The formula may still be intact but now has a blank or invalid input. Check the formula bar and inspect the cells it references. A formula that divides by a cleared or zero value can return an error; a lookup may return a not-found result if its key was removed. Decide whether that result is appropriate, or revise the formula to handle missing inputs. Do not delete the formula merely to hide an error.

You cannot edit the cells. Look for a protected-sheet message. If you are authorized to edit the sheet, choose Review > Unprotect Sheet and enter the password, if required. In a read-only workbook, use File > Save As to create an editable copy if your permissions allow it. If the workbook is shared or controlled by an organization, ask its owner for access.

The cells look empty but still behave as though they contain data. Select one and inspect the formula bar. A space, apostrophe, or formula returning an empty string can make a cell appear blank without making it truly empty. Use Find, filters, or Go To Special to locate the relevant content, then clear only the intended cells. If a formula returns an empty string, keep it if you want the calculation to remain available.

Frequently Asked Questions

Does pressing Delete in Excel remove a formula?
Yes. It clears the contents of the selected cells, including formulas. Select only input cells or use Go To Special to select constants while leaving formulas unselected.

How do I delete values but keep formatting?
Select the cells and choose Home > Clear > Clear Contents. This removes cell entries while retaining formatting, borders, and cell positions.

Can I clear all typed values on a sheet without clearing formulas?
Use Go To Special and select Constants, but first select the intended range and inspect the highlighted cells. Constants can include numbers, text, logical values, and errors, so adjust the options if you want to keep a particular type.

Why does my formula show blank after I clear an input?
The formula may still be present but designed to return an empty string when its input is blank. Click the cell and check the formula bar. A blank display does not necessarily mean the formula was deleted.

Will deleting a row change formulas elsewhere?
It can. Excel adjusts many cell references when rows are deleted, but formulas, charts, and links may behave differently depending on their references. If you only want to remove the row’s entered data and preserve the layout, clear its input cells instead.

Is clearing contents reversible?
Usually, yes: use Ctrl+Z on Windows or Command+Z on Mac soon after the action. Undo history can be lost after certain actions or after closing the workbook, so save a copy before a significant cleanup.

Related

Try it: the Formula Explainer: paste any formula and see each function and reference in plain English.

More in Formulas & functions

Sources: Function behaviour and menu paths: Microsoft Support documentation for Excel. Method & sources

Spotted an error in this guide? Let us know.