How to Delete Highlighted Cells in Excel & Google Sheets

Written by

Mel Jenkins

Reviewed by

Laura Tsitlidze

Last updated on December 9, 2022

This tutorial demonstrates how to delete cells highlighted with a fill color in Excel and Google Sheets.

 

removehighlightedrows intro

 

You can either delete rows with a specific background color using VBA, or you can filter your Excel worksheet by the color then delete the selected rows.

Filter by Color and Delete Selected Rows

  1. Click in the data where the cells/rows you want to remove are situated.
  2. In the Ribbon, select Home > Editing > Sort & Filter > Filter.
    OR
    Press CTRL + SHIFT + L on the keyboard.

 

removehighlightedrows filter

 

  1. Filter drop-down lists appear at the top of each column of data in the selected data. Select (1) one of the drop-down lists available in the column headers and then (2) select Filter by Color. Finally, (3) select the color you wish to filter on.

 

removehighlightedrows filter steps

 

These are the rows you are going to remove.

 

removehighlightedrows filtered

 

  1. Select the rows by clicking on the header of the first row to remove and dragging down to the last row you wish to remove, then, in the Ribbon, select Home > Cells > Delete > Delete Sheet Rows.

 

removehighlightedrows delete sheet rows

 

  1. The rows are removed. To clear the filter, select the filter button in the column you filtered on, and clear the filter from that column.

 

removehighlightedrows clear filter

 

The remaining data is shown.

 

removehighlightedrows final

 

Sort by Color and Delete Selected Rows

  1. Click in the data to be sorted, and then, in the Ribbon, select Home > Editing > Sort & Filter > Custom Sort.

 

removehighlightedrows ribbon sort

 

  1. Remove the (1) check mark from My data has headers, and then (2) select the column to sort by. Amend the Sort On to (3) Cell color and under Order (4) select the color of the cells you wish to remove.

 

removehighlightedrows customsort

 

  1. The rows are sorted to the top of the list. Select the rows by clicking on the header of the first row to remove and dragging down to the last row you wish to remove, then, in the Ribbon, select Home > Cells > Delete > Delete Sheet Rows.

 

removehighlightedrows delete sorted

 

Delete Highlighted Cells in Google Sheets

  1. You can also remove highlighted cells in Google Sheets by filtering by color.
  2. In the Data menu, select Create a filter.

 

removehighlightedrows gs create filter

 

  1. Then, (1) in the drop-down list of one of the column headers, select (2) Filter by color and then (3) select Fill Color and (4) select the color of the cells you wish to remove.

 

removehighlightedrows gs filter

 

  1. Select the rows of the filtered data and then (1) in the Edit menu, select (2) Delete and (3) Selected rows.

 

removehighlightedrows gs delete rows

 

The filter is automatically removed, and the remaining data is shown.

 

removehighlightedrows gs final

AI Formula Generator

Try for Free

See all How-To Articles