Published

How to Fix Reversed Credit Card Transactions in a CSV Import

Check a purchase, refund, and card payment to fix reversed amounts in a credit card CSV import and get both the balance and spending totals right.

An $80 shoe purchase shows up as money in after a credit card CSV import. The $20 refund shows up as spending. Before you flip a column, find one more row. A payment from checking should reduce both what you owe on the card and the money in your checking account. Compare all three rows with the original CSV to see where the directions went wrong.

A carved swallow and its paper print face opposite directions

Start with a purchase, a refund, and a payment

Keep the original CSV and work from a copy. Pick a posted purchase, a posted merchant refund you can trace to its purchase category, and a card payment you can find in checking. Open the file next to the import preview or, if you've already imported it, the account register.

In a ledger that uses negative amounts for outflows and positive amounts for inflows, a purchase is negative because it increases what you owe. The refund and payment are positive on the card because both reduce the debt. Put the refund back in the purchase category so it reduces spending there. If you track both accounts, match the card payment to the money that left checking and treat the pair as a transfer. Tracking merchant refunds, budgeting with credit cards

Fix the rule that reads the amount

Credit card CSVs can express positive and negative amounts in different ways. Start with the columns in your file.

  • One signed Amount column. Say the file has +80.00 for the purchase, -20.00 for the refund, and -100.00 for the payment, and the preview keeps those signs. The three rows point to a reversed sign convention for this card export. Check any other transaction types for that card before flipping its amount column. Use the importer's swap setting or add a new spreadsheet column with =-C2 if C2 contains the first amount. Fill the formula down and import that column with the swap setting off. If the file already has the right signs and the preview reverses them, check for a swap setting that's already on. YNAB file-based import, Tiller CSV import guide
  • Separate Debit and Credit columns. If the purchase sits in Debit and the refund and payment sit in Credit, map Debit to outflow and Credit to inflow. Swap that mapping if the rows sit in the opposite columns. Use the three known transactions to verify what the headings mean in this export.
  • Amount plus Type. When the amounts are unsigned, use the type to send purchases to outflow and refunds and card payments to inflow. For example, 20.00 on a Refund row becomes +20.00 in this ledger. If amounts already have signs, use the type to check them. Review unrecognized types and rows whose sign conflicts with the type before applying the mapping to the batch.

If only some rows imported backwards, follow those rows to their source column, type, or account rule. A purchase can come in correctly while a refund rule sends credits to outflow. Change that rule, then preview the corrected rows alongside the ones that were already right.

Try it with a three-row card CSV

Copy this sample into a test sheet. The card starts its October statement with $200 owed, recorded as -200.00 in the example ledger. All three transactions posted by the October 31 cutoff.

Posted Date,Description,Amount
2026-10-04,Shoe shop purchase,+80.00
2026-10-09,Shoe shop partial refund,-20.00
2026-10-15,Payment from checking,-100.00
Card row Corrected ledger amount What you owe after the row Budget treatment
Purchase -80.00 $280 $80 Clothing spend
Partial refund +20.00 $260 $20 back to Clothing
Payment from checking +100.00 $160 Incoming transfer

With the corrected amounts, the ledger closes at -200 - 80 + 20 + 100 = -160. The card statement shows that balance as $160 owed. With the raw signs, the ledger would close at -200 + 80 - 20 - 100 = -240, or $240 owed. The CFPB's sample statement shows the issuer's side of the same math. Purchases increase the amount owed, and payments and credits reduce it. CFPB sample credit card statement

This is the matching checking entry. The -100.00 is already in the right direction for the outgoing transfer.

Posted Date,Description,Amount
2026-10-15,Payment to credit card,-100.00

If checking opened at $600 and this was its only transaction, it closes at $500. Check the budget too. The $80 purchase minus the $20 refund leaves $60 in net Clothing spending. If the refund lands in income, both account balances still match and Clothing shows $80. Check that the payment links the two accounts as a transfer so it stays out of spending and income.

Repair the rows you've already imported

Find the affected rows by account and import ID if your tool provides one. Otherwise, match them to the source by posted date, description, and amount, allowing for the reversed sign. Fix confirmed rows in place when you can. If the tool requires a batch undo, check which rows it removes and whether the tool lets you reimport them. Compare any replacement rows with the entries that will still be in the ledger, including a checking payment you already recorded.

After saving, compare each account's posted balance at its own statement cutoff. The same payment can post on different dates in checking and on the card. Use each side's actual posted date when comparing its balance with the statement. Then confirm the category total and the payment's transfer classification in the saved ledger. Budget reconciliation walkthrough

Run the same checks in Nentaf

Nentaf's documented CSV workflow uses an external agent or script. Have it confirm the workspace and accounts, inspect the live schema, and show a preview with the source row, raw value, proposed signed amount, category, transfer match, and any duplicate candidates. For the shoe purchase and refund, use spend in Clothing with -80.00 and +20.00 respectively. A confirmed payment between tracked accounts is a pair of transfer entries with a shared event_id, one for -100.00 in checking and one for +100.00 on the card. Review the preview before approving writes, then check the saved balances and Clothing total. Nentaf Agent Setup, full statement import workflow

The CSV and balances are illustrative. The Nentaf example follows its documentation and source code. AI helped write the guide and generate the illustration.

Read next