A messy export cleaned up inside Sheets with Gemini

The struggle: You export a list from one tool and spend an hour fixing dates, duplicates and split names before anyone can use it.

What you end up with: A clean table in Google Sheets with consistent dates, no duplicates and the original export kept untouched.

Gemini in Sheets runs cleanup actions such as find and replace, number formats, sorting and filters, and shows a preview card before each change. You apply them one at a time on a copy.

Tools: Gemini. Level: Pro. Time: 30 min.

Use it if

  • The export comes from a CRM, a shop or a survey tool
  • Dates, names or numbers come in mixed formats
  • You need to hand the list to someone else

Skip it if

  • The sheet holds personal data you should not process this way
  • You need a one-off change a single find and replace already does

What you need first

  • Gemini in Sheets (an eligible Google Workspace or Google AI plan)
  • The export as a Google Sheet; for an Excel .xlsx file use File, then Save as Google Sheets first

The method

  1. Keep the original and open Ask Gemini (Gemini: Google Sheets)

    Import the export into a Google Sheet, then File, Make a copy, and work only on the copy. Click Ask Gemini at the top right and ask for a diagnosis before any change.

    Prompt to copy:

    Look at the data in this sheet and list the cleanup problems: mixed date formats, duplicate rows, names split across columns, extra spaces, numbers stored as text, blank rows. For each give the column, a count if you can tell, and two example rows. Do not change anything yet.

    You get: A list of problems in the data.

    Tip: Keep the untouched original in the same folder, so you can always go back.

  2. Apply one fix at a time (Gemini: Ask Gemini)

    Ask for one action, such as setting number formats or find and replace. Gemini shows a preview card. Read it, click Apply, then check the sheet before the next action. Undo works only until your next change.

    Prompt to copy:

    In column [letter] convert all dates to the format [YYYY-MM-DD]. Show me a preview first. If any value cannot be read as a date, leave it unchanged and highlight the cell.

    You get: One problem fixed and checked.

    Tip: Fix one thing, look, then ask for the next, because Undo only reaches back one change.

  3. Handle duplicates and split names (Gemini: Ask Gemini)

    Ask Gemini to flag duplicates before removing anything. Review the flagged rows, then ask it to sort or filter them out. Do not delete rows you have not looked at.

    Prompt to copy:

    Flag rows in this sheet that look like duplicates, using [column, e.g. email] as the key. Mark them in a new column with the row number of the first match. Do not delete anything. Then I will review.

    You get: Duplicates flagged, reviewed and removed on the copy.

    Tip: Define what counts as a duplicate: same email beats same name, because two people can share a name.

  4. Spot-check against the original (Gemini: Google Sheets)

    Compare 10 random rows and the row count with the original export. Then format the range as a table and add a note tab listing what you changed.

    You get: A clean, checked table and a change note.

    Tip: Check the row count against the original before and after, so nothing is lost without you knowing.

Where this goes wrong

  • Each action shows a preview and you must click Apply; read it, because Gemini can change more cells than you meant
  • Undo only works until your next change, so work one step at a time on a copy
  • Gemini conversation history is lost on reload; keep a note of what you changed

Sources

More like this

Updated . Written with AI help and checked by an independent review step, as described in our editorial standards.