To merge duplicate rows in Excel without losing data, group the rows first, then copy each missing value onto the row you keep, and only then delete the rest. Remove Duplicates does the reverse: it keeps the first row it meets and deletes the others, together with any phone number, title or note that only a deleted row held.
This article compares the three ways to do the merge properly, shows what each one costs in time on a real file, and ends with a worked example from the DataUntangler engine, where every filled and differing value lands in a change log.
Why Remove Duplicates loses data
Microsoft describes the command as deleting rows whose selected columns hold the same values, and it keeps the first occurrence, as the Microsoft support page explains. Which row comes first is decided by how the sheet happens to be sorted, not by which row is more complete.
A contact appears twice. The first row has a name and a job title. The second row, entered a month later, has the same email, a phone number and a note that the customer wants annual billing. Remove Duplicates on the email column keeps the first row, and the phone number and the note are gone with no record that they existed.
The command also needs the duplicates to be exact. If they are not, it removes nothing, which is covered in the guide to removing duplicates in Excel.
Three ways to merge duplicate rows and keep the data
The first three share a limit that matters more than speed: they merge on an exact key. If one row says Jon Holt and the other Jonathan Holt with a different email, no formula connects them. That is the situation described on the fuzzy duplicate finder for Excel page.
| Method | How it keeps data | Where it breaks | Time on 5,000 rows |
|---|---|---|---|
| Sort, then fill by hand | You copy each missing value onto the row you keep | Easy to skip a column, no record of what moved | Hours |
| Formulas such as TEXTJOIN with FILTER, or a helper column with XLOOKUP | Pulls every value for one key into the kept row | Needs Excel 2019 or Microsoft 365, breaks when the key has typos | About an hour to build, then reusable |
| Power Query Group By | Groups on the key and combines text with a custom Text.Combine step | Takes custom M code, and the key must still match exactly | About an hour to build |
| A review tool that merges groups and logs each fill | Fills empty cells of the kept row and logs differing values | Works on an exported file, not inside the workbook | Minutes |
Times are rough estimates for a first-time build on a clean 5,000 row sheet, not measurements.
A worked example with a six row contact list
This is a real run of the engine on an invented six row file with five columns: email, name, phone, title and notes. It has two pairs of rows that share an email address.
In the first pair, Marta Reyes appears twice. The kept row has the phone number and the note, the other row has the job title Operations Manager. The engine grouped them with high confidence, because the email is the same once case is ignored, and filled the empty title on the kept row from the removed row. Nothing was lost.
In the second pair, Jon Holt appears twice with the same email and the same phone, but one row says Director and the other says VP Operations. The engine grouped the rows as likely and listed the title as a conflict. It does not pick one silently. The removed value is written to the change log so you can see both and choose.
The log had one line for the filled title and one for each differing value, so any value that left the sheet has a line that says where it went. The two single rows, Ana Kim and Ben Ortiz, were left as they were.
Which method fits which file
Under about 300 rows with true copies, the formula route is fine and costs nothing. Past a few thousand rows, or when the same customer is typed several ways, the building time of formulas and queries passes the price of a tool, and the exact key still limits what they catch.
Analyst is $59 a month, or $348 a year, for one person and files up to 100,000 rows. There is no free plan. The browser demo runs a real pass on a file of your own, and the pricing page lists the plan.
If the list is a customer or vendor list headed for an invoice run or a CRM import, the pass is part of the routine described on Excel data cleaning, and the same logic for CRMs sits on customer deduplication software.
How the formula route works on a small file
If you stay in Excel, the least risky pattern is a helper column. Sort the sheet by the key, for example the email address, and add a column that counts how many times the key has appeared so far with COUNTIF over an expanding range. Rows with a count of 1 are the survivors, rows with 2 or more are the extras.
Then pull the missing values onto the survivor. In Microsoft 365, TEXTJOIN with a FILTER on the key joins every phone number or note held by rows that share that key into one cell. In older versions the same job takes a longer formula chain or a macro. Check the result by eye for the first twenty keys before you trust it for the rest.
Only after the values sit on the survivor do you filter the extras and delete them. Delete on a copy of the workbook, and keep the original sheet until the totals match. A common mistake is deleting first, because the formulas then point at rows that no longer exist.
The limit of this route is the key. Email addresses with a trailing space, a different case or a typo make two keys that look equal and are not, so clean those first. The Excel data cleaning page covers that step, and it is the reason many teams put a reviewed pass in front of the merge rather than after it.
A checklist before you delete any merged row
Keep the original file untouched and merge on a copy. Decide which row is the survivor by completeness, not by sort order. Fill empty cells on the survivor before deleting anything. Write down every value that differs between the rows, then choose. Check the total row count before and after, so a count of rows removed matches the number of groups you approved.
Save the change log with the file. A month later, when someone asks where a phone number went, the answer should be one line, not a search through old versions.