26 November 2026 · Practical AI builds
How do I clean up a messy contact spreadsheet with AI?
By the end of this you will have a contact spreadsheet where every name, phone number and address follows the same pattern, plus a column showing which rows the AI was unsure about. It suits anyone with a list that has grown over years from forms, business cards and old exports, and who wants it tidy without retyping it all by hand.
I learn my automation tips in the AI Profit Boardroom. Have a look here. Affiliate link.
What you need
- Your contact list in a spreadsheet program (Excel, Google Sheets or LibreOffice Calc all work).
- Access to an AI chat tool or API. Free tiers often limit how much text you can paste at once, and paid plans or API use cost money.
- A short written list of how you want things to look, your own "house style".
- About an hour for a list of a few hundred rows, most of it spent checking.
Step by step
- Make a copy of the original file and never edit it. Work only on the copy, so you can always go back.
- Add a column called
row_idand number every row 1, 2, 3 and so on. This is how you will match the AI's output back to the original and spot any row that goes missing. - Do the easy fixes with the spreadsheet itself first. Functions such as
TRIMremove stray spaces andPROPERcapitalises names, and they are faster and more reliable than AI for simple jobs. - Write down your house style in plain words. For example: names as "First Last", UK mobiles as "07700 900123", landlines with a space after the area code, postcodes in capitals with one space, county left blank if unknown.
- Remove any columns the AI does not need, such as notes, birthdays or account numbers. Send only the fields you want cleaned plus the
row_id. - Export a batch of 50 to 100 rows as CSV text. Small batches are easier to check and less likely to come back cut short.
- Give the AI your house style and the batch, and ask it to return the same rows in the same order with one extra column for anything it was unsure about. A prompt like the one below works well.
- Paste the result into a new sheet and check the row count matches the batch. Then spot-check ten rows against the original by
row_id. - Look at every row with something in the flag column and fix those by hand. Repeat for the next batch until the list is done.
- Once all batches are back, put the removed columns back by matching on
row_id, and keep the original file until you are confident in the new one.
You are cleaning a contact list. Follow these rules exactly:
- Names: "First Last", capitalised normally (keep Mc, Mac, O' and hyphens).
- UK mobiles: 07700 900123. UK landlines: area code, space, number.
- Postcodes: capitals, one space before the last three characters.
- Do not invent anything. If a value is missing or unclear, leave it
as it was and explain in the "flag" column.
- Return every row, in the same order, as CSV with the same columns
plus "flag". Do not merge, drop or add rows.
row_id,name,phone,address,postcode
1, JOHN smith ,+44 7700900123,12 high st example town,ex1 1aa
2,mary o'neil,07700-900456,flat 3 the mews,EX11ABWhat good looks like
Every batch comes back with the same number of rows you sent, the row_id values run in order with no gaps, and your spot-checks show the same person, number and address, just written the consistent way. The flag column catches the genuinely odd entries, such as a phone number with a digit missing, rather than staying empty. If you sort by phone or postcode, near-duplicates of the same contact now sit next to each other, which makes them easy to spot.
Watch out for
AI can quietly change things it should not. It may "fix" an unusual surname, guess a missing postcode, drop a row or merge two similar people. That is why the row_id, the row count check and the spot-checks matter: never paste the result over your only copy. Contact lists are also personal data, so check your AI provider's terms on how long it keeps what you send and whether it trains on it, and send only the columns you need. There is more on that in how to keep private data out of AI tools. If you plan to reuse the same prompt on every batch, it is worth testing the prompt properly on a few awkward rows first.
Questions people ask
Can the AI also remove duplicate contacts?
It can suggest likely duplicates, but let it flag them rather than delete them. Two people at the same address with similar names are often different people, so a human should make the final call.
Will it check that phone numbers and addresses are real?
No. A chat model only reformats what you give it and cannot confirm that a number works or an address exists. For that you would need a separate address lookup or validation service, which usually costs money.
In short: do the simple fixes in the spreadsheet, give the AI clear rules and small batches, keep a row number on everything, and check the results before you trust them. The AI does the dull retyping and you keep the final say.
Want more automation tips? The AI Profit Boardroom on Skool is where I get mine. Have a look here. Affiliate link.