Excel data cleaning

How to Remove Blank Rows in Excel (Fast, Without Deleting Real Data)

By the DecodingPro teamUpdated 4 min read

Quick answer

Select your data, press F5 then Special, choose Blanks and click OK. Excel selects every empty cell; right-click one of them, choose Delete, then Entire row. This is safe only if a row is blank all the way across. If a row has a value in any column, this method would delete it too, so use the filter method below instead.

Blank rows break sorting, filtering, pivot tables and imports. They usually come from exports, copied tables and rows someone cleared instead of deleting. The fast method has one trap that deletes real data, so read the warning before you use it.

Method 1: Go To Special (rows that are empty across)

  1. Click in your data and press Ctrl+A to select it.
  2. Press F5, click Special, choose Blanks, then OK.
  3. With the blank cells selected, right-click one of them and choose Delete.
  4. Choose Entire row and click OK.

Warning: this selects every blank cell, not every blank row. A row with a name but no phone number has a blank cell, and the steps above would delete the whole row. Use this method only when the rows to remove are empty in every column, or work on a single column that is always filled in.

Method 2: a helper column and a filter (the safe way)

Add a column next to your data that counts how many cells in each row have something in them:

=COUNTA(A2:H2)

Change H to your last column. Fill down. A result of 0 means the row is empty across. Then filter that helper column to show only 0, select the visible rows, right-click a row number, choose Delete Row, and remove the filter. Rows that have even one value are never touched.

Method 3: sort the blanks to the bottom

If the order of your rows does not matter, sort by a column that is always filled. Excel puts empty cells last, so the blank rows gather at the bottom where you can delete them in one go. If the order does matter, add a numbering column first (1, 2, 3...) and re-sort by it afterwards to restore the original order.

Method 4: Power Query (repeatable)

On the Data tab choose From Table/Range. In the Power Query window open Remove Rows on the Home tab and choose Remove Blank Rows, then Close & Load. Power Query only removes rows that are blank in every column, and it repeats the step when you refresh, which is useful for an export you receive every week. See cleaning data with Power Query for more.

Rows that look empty but are not

Sometimes a row looks blank yet Go To Special does not find it. The cells contain a space, an apostrophe, a formula that returns an empty string, or an invisible character. Excel counts those as filled. To see it, check the length of the cell with =LEN(A2): anything above 0 is not truly empty. Clean the cells first with =TRIM(CLEAN(A2)), which is covered in removing extra spaces in Excel, and then remove the rows.

Always keep a copy

Deleting rows cannot always be undone once the file is saved and closed. Save a copy of the file first, or work on a copy of the sheet. Then compare the row count before and after: it should drop by exactly the number of blank rows you expected.

A whole file at once

DecodingPro reads every sheet, ignores rows that are truly empty, trims invisible spaces that make a row look filled, and flags cells that are empty where the rest of the column is filled, rather than deleting anything for you. Every change is logged.

Try it on your own file

You start with 100 free credits. Every change is logged, and anything unclear is flagged, never guessed.

Fix a spreadsheet

Questions people ask

How do I delete all empty rows in Excel at once?

Select the data, press F5, Special, Blanks, then right-click a selected cell, Delete, Entire row. Only do this if the empty rows are blank in every column, otherwise use a COUNTA helper column and a filter.

Why did Excel delete rows that had data?

Go To Special selects blank cells, not blank rows. Deleting the entire row for a blank cell removes the row's other values too. Use the COUNTA helper column method to be safe.

Why can't Excel find my blank rows?

The cells are not truly empty. They hold a space, an apostrophe or a formula returning an empty string. Check with =LEN(A2), clean the cells, then try again.

Can I remove blank rows automatically every time I get a file?

Yes, with Power Query: the Remove Blank Rows step is saved with the query, so it runs again on Refresh.

Keep reading

01Excel data cleaningHow to Clean Messy Excel Data: A Step-by-Step GuideThe fixed order that stops one fix from undoing another, with the formulas for every step.10 min read02Text and numbersHow to Keep Leading Zeros in Excel and CSV (ZIP Codes, IDs)Why Excel turns 02134 into 2134, how to get the zeros back, and how to stop it happening when you open a CSV.5 min read03CSV and importsHow to Clean a CSV File Before Importing It Into a CRMSeven fixes that prevent duplicate contacts, rejected rows and scrambled characters, and the 10-row test to run first.4 min read04DatesHow to Fix Dates in Excel and CSV Files (Mixed Formats)Text dates, day-month swaps, two-digit years and the one rule that makes dates safe to share.8 min read05Phone numbersHow to Fix Phone Numbers in Excel: Format and Country CodesLeading zeros, 9.19E+11, country codes and the international format that every system accepts.6 min read06DuplicatesHow to Remove Duplicates in Excel Without Losing DataExact, near and partial duplicates: decide what counts, mark before you delete, keep the best record.6 min read07DuplicatesHow to Find and Highlight Duplicates in ExcelFind repeats safely first: highlight them, count them, keep the first one, and spot the near-duplicates Excel does not see.3 min read08NamesHow to Standardize Names in Excel: Proper Case and ExceptionsWhat PROPER gets wrong, how to protect names that are already right, and how to flip "Smith, John" into "John Smith".4 min read09Email addressesHow to Fix Email Typos in Excel: gmial.com, .con and Missing @The typos that make campaigns bounce, and the formulas and checks that fix them without guessing.4 min read10Email addressesHow to Clean an Email List Before You Send a CampaignA five-step routine that removes the avoidable bounces from a list without deleting anyone you should keep.3 min read11NamesHow to Split Full Names into First and Last Name in ExcelFlash Fill, Text to Columns and formulas for splitting names, and the names that trip each one up.4 min read12Text cleanupHow to Remove Extra Spaces in Excel (TRIM, CLEAN and Non-Breaking Spaces)Why TRIM sometimes does nothing, and the one formula that removes every kind of stray space.3 min read13Text cleanupHow to Remove Special Characters and Line Breaks in ExcelThe characters you cannot see, the smart quotes you can, and the exact formula or shortcut that removes each one.4 min read14NumbersHow to Convert Text to Numbers in Excel (Numbers Stored as Text)Why sums show zero, why numbers sit on the left, and four ways to turn text back into real numbers.3 min read15Excel data cleaningHow to Clean Data with Power Query in Excel (Step by Step)Record your cleaning steps once and replay them on every new file, without formulas and without touching the original data.4 min read16Comparing dataHow to Compare Two Lists in Excel and Find What Is MissingFind the names, IDs or emails that are in one list and not the other, with formulas that scale.3 min read17CSV and importsFix Garbled Characters and Broken CSV Imports (UTF-8)UTF-8, delimiters, leading zeros, quotes and a checklist that makes a file safe to import.7 min read18Data entryData Entry Accuracy: How to Check, Measure and Improve ItWhat the research says about error rates, why proofreading fails and the checks that actually work.9 min read19Excel data cleaningVLOOKUP Not Working in Excel? Fix #N/A, Hidden Spaces and Text NumbersVLOOKUP says #N/A but the value is right there. The five causes, and how to find which one you have in a minute.4 min read21Email addressesHow to Validate Email Addresses in Excel (Formulas, Typos and What They Miss)A formula that flags broken addresses, how to catch gmial.com-type typos, and the limit of any check done in a spreadsheet.5 min read22Excel data cleaningHow to Find and Fix Typos in an Excel Column (Cities, Names, Categories)Spot Bostn next to Boston in a column of thousands, and fix the typos without touching values that are merely similar.5 min read