Skip to main content

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


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 30 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:

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.

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 300 handy Excel add-ins, free to try with no limitation in 30 days. Download and free trial Now!

Best Office Productivity Tools

🤖 Kutools AI Aide: Revolutionize data analysis based on: Intelligent Execution   |  Generate Code  |  Create Custom Formulas  |  Analyze Data and Generate Charts  |  Invoke Kutools Functions
Popular Features: Find, Highlight or Identify Duplicates   |  Delete Blank Rows   |  Combine Columns or Cells without Losing Data   |   Round without Formula ...
Super Lookup: Multiple Criteria VLookup    Multiple Value VLookup  |   VLookup Across Multiple Sheets   |   Fuzzy Lookup ....
Advanced Drop-down List: Quickly Create Drop Down List   |  Dependent Drop Down List   |  Multi-select Drop Down List ....
Column Manager: Add a Specific Number of Columns  |  Move Columns  |  Toggle Visibility Status of Hidden Columns  |  Compare Ranges & Columns ...
Featured Features: Grid Focus   |  Design View   |   Big Formula Bar    Workbook & Sheet Manager   |  Resource Library (Auto Text)   |  Date Picker   |  Combine Worksheets   |  Encrypt/Decrypt Cells    Send Emails by List   |  Super Filter   |   Special Filter (filter bold/italic/strikethrough...) ...
Top 15 Toolsets12 Text Tools (Add Text, Remove Characters, ...)   |   50+ Chart Types (Gantt Chart, ...)   |   40+ Practical Formulas (Calculate age based on birthday, ...)   |   19 Insertion Tools (Insert QR Code, Insert Picture from Path, ...)   |   12 Conversion Tools (Numbers to Words, Currency Conversion, ...)   |   7 Merge & Split Tools (Advanced Combine Rows, Split Cells, ...)   |   ... and more

Supercharge Your Excel Skills with Kutools for Excel, and Experience Efficiency Like Never Before. Kutools for Excel Offers Over 300 Advanced Features to Boost Productivity and Save Time.  Click Here to Get The Feature You Need The Most...

Description


Office Tab Brings Tabbed interface to Office, and Make Your Work Much Easier

  • Enable tabbed editing and reading in Word, Excel, PowerPoint, Publisher, Access, Visio and Project.
  • Open and create multiple documents in new tabs of the same window, rather than in new windows.
  • Increases your productivity by 50%, and reduces hundreds of mouse clicks for you every day!
Comments (2)
No ratings yet. Be the first to rate!
This comment was minimized by the moderator on the site
Отличная подробная статья! Спасибо!
This comment was minimized by the moderator on the site
Thanks for the detailed instructions. It worked perfectly! Keep up the great information.
There are no comments posted here yet
Please leave your comments in English
Posting as Guest
×
Rate this post:
0   Characters
Suggested Locations