Security

Removing names and numbers before giving a statement to AI

Step-by-step spreadsheet method to anonymise a bank statement for AI: delete header rows, mask account numbers and swap payee names for labels before pasting.

Editorial illustration for Removing names and numbers before giving a statement to AI

To anonymise a bank statement for an AI assistant, open it as a CSV or Excel file, delete the header and balance columns, mask account and phone numbers, replace payee names with neutral labels and keep only dates, amounts and categories. The whole job takes ten to fifteen minutes in Excel or Google Sheets, and you keep the untouched original on your own device.

What should you keep and what should go?

Start by deciding what the question needs. If you want to know where the money went, the answer lives in three things: the date, the amount and a category. Everything else is optional.

Column or detailKeep or removeReason
Transaction dateKeepNeeded for month-wise patterns
Debit and credit amountsKeepThe core of the analysis
NarrationShorten to a labelIt often holds names and phone numbers
Balance columnRemoveShows how much you hold
Account number, name, addressRemoveIdentifies you directly
UTR or reference numberRemoveLinks back to a specific payment

How do you do it step by step?

  1. Work on a copy. Save the downloaded file under a new name and never edit the original.
  2. Delete the rows above the transaction table: customer name, address, account number, statement period banners and any footer notes.
  3. Delete the balance column and any reference or cheque number column.
  4. Add a new column called Label next to the narration. This is where your neutral descriptions go.
  5. Fill the Label column, starting with the biggest and most personal lines, using the find-and-replace method below.
  6. Delete the original narration column once Label is complete.
  7. Scan the file one last time by sorting on amount, because large, odd transactions are where stray names hide.

What does a find-and-replace example look like?

Say a narration reads UPI/DR/Ramesh Kumar/9876543210/rent. In your sheet, use Find and Replace with these pairs, running Replace All for each.

  • Find Ramesh Kumar, replace with Landlord.
  • Find 9876543210, replace with PHONE.
  • Find the name of your tutor or doctor, replace with Tutor or Doctor.
  • Find your employer's name on the salary credit, replace with Salary.

The row now reads UPI/DR/Landlord/PHONE/rent, which still tells the assistant it is a rent payment and tells a reader nothing. Phone numbers vary, so also sort the narration column and look for any ten-digit run you missed. If your sheet supports it, Excel and Google Sheets both let you tick Match entire cell contents off, so partial matches inside longer text are replaced.

How do you mask numbers that follow no pattern?

Account numbers, card fragments and UPI handles do not always sit in one place. Use Find with the first few characters, such as the first four digits of the account number, and replace the whole string you find with XXXX. Do the same for handles that end with an at-sign and a bank code: replace each with a label. If you are doing this regularly, keep a short list of your own find-and-replace pairs in a note so the next month takes five minutes.

Does anonymising make it completely safe?

No. A pattern of dates and amounts can still point to you, for example a unique salary figure on a particular day. Anonymising lowers the exposure, it does not remove it. Share the smallest slice that answers your question, such as one month or one category, and read the assistant's data settings before you paste. If you want an answer without handing over rows at all, a tracker that already holds the data can summarise it for you. SpendixAI, for instance, lets you import a statement, review each row and then see categorised reports, so you can paste only a monthly total into a chat.

Final check before you paste

  • Header, balance and reference columns are gone.
  • No ten-digit phone numbers, account digits or UPI handles remain in any cell.
  • Labels replace every personal payee.
  • The file name and tab names are neutral.
  • You can still tell what each row is about, which means the AI can too.
SPENDIXAI JOURNAL

Useful ideas start with a clearer picture of your own spending.

Explore your reports