Tip: Other languages are Google-Translated. You can visit the English version of this link.
Log in
x
or
x
x
Register
x

or

How to remove everything but duplicate rows in Excel?

Maybe, there are some duplicate values in a column of your worksheet, and now, you want to remove non-duplicate values and keep only the duplicate records in the column. Do you have any good ideas to solve this problem in Excel? In this article, I will talk about how to quickly and easily remove all but keeping the duplicate rows in Excel.

Remove everything but duplicate rows with a helper column

Remove everything but duplicate rows with Kutools for Excel


Remove all unique values and keep only the duplicates:

With Kutools for Excel's Select Duplicate & Unique Cells feature, you can quickly select the duplicate or unique values in a list and then you can format, copy or delete them as you need.

doc remove all but duplicates 15

Kutools for Excel: with more than 200 handy Excel add-ins, free to try with no limitation in 60 days. Download and free trial Now!



To remove the non-duplicate rows, you need to create a formula helper column first, and then filter all the unique values based on your helper column, finally, delete the filtered unique values. Please do as follows:

1. Enter this formula =COUNTIF($A$2:$A$15, A2)=1 into a blank cell besides your data, such as cell B2, see screenshot:

doc remove all but duplicates 1

Tip: In the above formula, A2:A15 is the column range you want to remove the unique values, you can change it as you need.

2. And then drag the fill handle down to the cells that you want to apply this formula, False indicates the duplicate values and True stands for the unique values, see screenshot:

doc remove all but duplicates 2

3. Then select the data range and click Data > Filter, see screenshot:

doc remove all but duplicates 3

4. Click the filter drop-down in the new helper column B and uncheck FALSE option to just show the unique values of column A, and then click OK button, see screenshot:

doc remove all but duplicates 4

5. After showing only the non-duplicate records, select the entire rows of these visible rows, and then click Home > Find & Select > Go To Special, in the Go To Special dialog box, select Visible cells only option, see screenshots:

doc remove all but duplicates 5  2 doc remove all but duplicates 6

6. Then click OK to close the dialog box, and only the visible rows have been selected as following screenshot shown:

doc remove all but duplicates 7

7. And then you need to remove these visible rows only, put the cursor at the selected rows, right click to choose Delete Row from the context menu, see screenshot:

doc remove all but duplicates 8

8. And only the visible rows are deleted at once, then you need to cancel the filter by clicking Data > Filter again to disable the Filter function, and you can see all the unique value rows have been removed, and only leave the duplicate records, see screenshot:

doc remove all but duplicates 9

9. At last, you can delete the content of helper column B as you want.


With above method, there are so many steps needed to be followed, if you have a handy tool – Kutools for Excel, it may save you a lot of time.

Kutools for Excel : with more than 300 handy Excel add-ins, free to try with no limitation in 60 days

After installing Kutools for Excel, please do as follows:

1. Select the data range that you want to use.

2. Then click Kutools > Select > Select Duplicate & Unique Cells, see screenshot:

doc remove all but duplicates 10 10

3. In the Select Duplicate & Unique Cells dialog box, select Unique values only under the Rule section, and check Select entire rows option, see screenshot:

doc remove all but duplicates 11 11

4. Then click OK button, and a prompt box will pop out to remind you how many rows have been selected:

doc remove all but duplicates 12 12

5. And then click OK to close theses dialogs, and all the unique value rows have been selected, see screenshot:

doc remove all but duplicates 13 13

6. Then you just need to remove theses selected rows, click Home > Delete > Delete Sheet Rows, see screenshot:

doc remove all but duplicates 14 14

7. And all the selected unique rows have been deleted immediately.

If you are interested in our Select Duplicate & Unique Cells utility of Kutools for Excel, please click to know more.

With this Select Duplicate & Unique Cells feature, you can also finish the following tasks:

How to find duplicate rows in a range in Excel?

How to filter or select unique records from selected range in Excel?

How to remove duplicates and replace with blank cells in Excel?

Download  and free trial Kutools for Excel Now !


Kutools for Excel: with more than 200 handy Excel add-ins, free to try with no limitation in 60 days. Download and free trial Now!


Excel Productivity Tools

Ribbon of Excel (with Kutools for Excel installed)

300+ Advanced Features Increase Your Productivity by 70%, and Help You To Stand Out From Crowd!

Would you like to complete your daily work quickly and perfectly? Kutools For Excel brings 300+ cool and powerful advanced features (Combine workbooks, sum by color, split cell contents, convert date, and so on...) for 1500+ work scenarios, helps you solve 80% Excel problems.

  • Deal with all complicated tasks in seconds, help to enhance your work ability, get success from the fierce competition, and never worry about being fired.
  • Save a lot of work time, leave much time for you to love and care the family and enjoy a comfortable life now.
  • Reduce thousands of keyboard and mouse clicks every day, relieve your tired eyes and hands, and give you a healthy body.
  • Become an Excel expert in 3 minutes, and get admiring glance from your colleagues or friends.
  • No longer need to remember any painful formulas and VBA codes, have a relaxing and pleasant mind, give you a thrill you've never had before.
  • Spend only $39, but worth than $4000 training of others. Being used by 110,000 elites and 300+ well-known companies.
  • 60-day unlimited free trial. 60-day money back guarantee. Free upgrade and support for 2 years. Buy once, use forever.
  • Change the way you work now, and give you a better life immediately!

Office Tab Brings Efficient And Handy Tabs to Office (include Excel), Just Like Chrome, Firefox, And New IE

  • Increases your productivity by 50% when viewing and editing multiple documents.
  • Reduce hundreds of mouse clicks for you every day, say goodbye to mouse hand.
  • Open and create documents in new tabs of same window, rather than in new windows.
  • Help you work faster and easily stand out from the crowd! One second to switch between dozens of open documents!
Say something here...
symbols left.
You are guest ( Sign Up? )
or post as a guest, but your post won't be published automatically.
Loading comment... The comment will be refreshed after 00:00.

Be the first to comment.