How to Reconcile a Contra Entry in Xero
When a supplier is also your customer, rule-based tools post the money twice. Here is how to net it correctly in Xero — no manual workaround.
A supplier who is also your customer is where every rule-based reconciliation tool quietly posts the same money twice.
The scenario is common: you buy services from a company and they buy services from you. At month-end you agree to net the balances — no cash changes hands, or only the difference does. It sounds simple. In Xero, it takes four or five manual steps and a clearing account that most founders have never set up. If you skip the clearing account and try to match through the bank feed instead, you get a reconciled-looking bank line that leaves both the invoice and the bill sitting open. Your debtor ledger is wrong. Your creditor ledger is wrong. Your year-end accountant will find it.
This is a contra entry. Here is why it breaks on rule-based tools, what the correct Xero method is, and how TheBookkeeper.ai handles it without you touching the clearing account at all.
What a Contra Entry Actually Is
The netting agreement explained
A contra, in the UK bookkeeping sense, is a set-off between a trade debtor balance and a trade creditor balance for the same entity. You owe them £2,400 for design work. They owe you £1,800 for copywriting. Rather than two bank transfers crossing each other, you agree to net: they pay you the £600 difference.
The correct accounting is:
- Your sales invoice of £1,800 closes (income received, debtor cleared).
- Your purchase bill of £2,400 partially closes for £1,800 (creditor reduced by £1,800).
- A cash payment of £600 settles the remaining creditor balance.
Nothing is reversed. No revenue disappears. The £600 bank receipt is matched to the remaining £600 creditor balance, not to the full £2,400 bill. Done correctly, both ledgers are clean.
What goes wrong without a clearing account
Done incorrectly — which is what rule-based tools tend to produce — the bank feed sees the £600 receipt, matches it to the sales invoice (wrong: the invoice was for £1,800), leaves the bill entirely open, and calls the bank line reconciled. You now have an inflated debtor ledger, an untouched creditor ledger, and a bank line ticked off against the wrong document.
The Named Problem
Two businesses, one netting arrangement
Indigo Heron Ltd is a small digital agency. They use Green Otter Consulting for monthly SEO reports (£2,400 inc VAT). Green Otter also buys monthly blog copy from Indigo Heron (£1,800 inc VAT).
At the end of May, the two finance contacts agree to contra: Indigo Heron will send one invoice, Green Otter will send one invoice, and only the £600 difference will move in cash. Green Otter sends Indigo Heron a BACS payment of £600 on 31 May.
In Xero, Indigo Heron now has:
- An outstanding sales invoice (INV-0042) for £1,800 to Green Otter Consulting — awaiting payment.
- An outstanding purchase bill (BILL-0017) for £2,400 from Green Otter Consulting — awaiting payment.
- A bank feed line on 31 May showing a receipt of £600 from GREEN OTTER CONSULT.
Why the £600 bank line is the wrong starting point
The bank feed line is the only cash event. The £1,800 contra needs to be posted with no cash behind it.
If you match the £600 bank receipt directly to INV-0042, Xero will raise the alarm that the amounts don’t match — but a less careful click-through can force the reconciliation anyway, leaving a £1,200 unallocated payment on the contact’s account. If you match to BILL-0017 — the bill is for £2,400 and the receipt is £600, so Xero would post a part-payment of £600 against the bill and leave £1,800 of the bill unpaid, while INV-0042 stays open entirely. Either way, you have two inaccurate ledger balances.
The right method requires a clearing account — and most bank rules cannot construct one.
Why the Conventional Approach Breaks
Xero’s bank feed and JAX
Xero’s automatic reconciliation layer, JAX, is built on pattern matching between bank amounts and invoice amounts. It looks for a bank line that matches an open invoice or bill by amount, contact, and approximate date. The £600 bank line does not match INV-0042 (£1,800) or BILL-0017 (£2,400). JAX will leave it unreconciled and surface it for manual review — which is the correct outcome, but it means the work has not been done.
Xero bank rules
A bank rule can say: “if the description contains GREEN OTTER, code to account 4000.” That will categorise the £600 and reconcile the bank line. It will not touch INV-0042. It will not touch BILL-0017. Both stay open on the ledger. The rule has resolved the bank feed and broken the ledger simultaneously. This is the double-posting problem in its most misleading form: the bank says reconciled, but neither the debtor nor the creditor balance is correct. As Xero Central confirms, bank rules apply only to bank lines — they have no visibility into what invoices or bills a contact has outstanding.
Rule-based tools (Otto, Booke, similar)
These extend pattern matching further — smarter description parsing, ML-based categorisation. The problem is not the pattern match; it is that a contra requires a two-leg posting with a clearing account in between, which is a journal operation, not a bank feed operation. No bank rule, however intelligent, produces a journal. The structure of the problem is outside rule-based architecture.
AI copilots
Claude with Xero MCP access, or similar AI-assistant tooling, can generate the correct journal if you describe the scenario clearly and supervise the output. The work is now faster and the chance of error lower — but it is still your work. You open the tool, describe the contra, review the suggested clearing account entries, post them, then return to the bank feed and match the £600. A contra takes four to six minutes with AI assistance rather than fifteen without. It still takes four to six minutes.
Human bookkeepers
A good UK bookkeeper handles contras routinely. They create the clearing account, post both sides, reconcile the cash movement, and verify the ledger is clean. At £30–£60 per hour, that is a reasonable cost for a monthly contra — but the work happens on their schedule, not yours, and your ledger stays in an unreconciled state until they log in.
How We’d Actually Solve It
Detecting the contra pattern automatically
When Indigo Heron’s £600 bank receipt lands in Xero, TheBookkeeper.ai sees three things simultaneously: the new unreconciled bank line, the open sales invoice INV-0042 (£1,800, Green Otter Consulting), and the open purchase bill BILL-0017 (£2,400, Green Otter Consulting).
It identifies the contra pattern: same contact, one debtor balance, one creditor balance, an incoming cash amount equal to the difference. It does not need to be told this is a contra — the relationship between the three amounts and the shared contact name is the signal.
The five-step posting sequence
Its posting sequence is:
-
Verify the clearing account exists in Indigo Heron’s chart of accounts. If a “Contra / Inter-Company Offset” current liability account exists, it uses it. If not, it flags the gap and proposes creating one before proceeding.
-
Post the non-cash contra leg via a payment against INV-0042 for £1,800, coded to the clearing account. This closes the sales invoice. The clearing account now holds a £1,800 credit.
-
Post the matching payment against BILL-0017 for £1,800, also coded to the clearing account. The clearing account balance returns to zero. The purchase bill is now partly settled — £1,800 applied, £600 outstanding.
-
Match the £600 bank receipt to the remaining £600 balance on BILL-0017. The bank line is reconciled. The bill is fully paid.
-
Write the narration on each posting: “Contra with Green Otter Consulting, May 2026 — offset INV-0042 against BILL-0017. Cash difference £600 received 31 May.”
You wake up to a reconciled bank line, a zero balance on the clearing account, INV-0042 showing paid, and BILL-0017 showing paid. The narration on every posting is there for your accountant to read without asking you to explain it.
What TheBookkeeper.ai flags rather than posts: if the contra amounts don’t net cleanly — for instance, if the two invoices include VAT at different rates and the netting creates a fractional unallocated balance — it surfaces this for your approval before posting. VAT on contras is a real edge case; the tax point on each invoice may differ from the payment date, which matters for your VAT return.
Worked Example
The scenario
Indigo Heron Ltd (digital agency, Xero, UK VAT-registered) and Green Otter Consulting have agreed a monthly contra arrangement. May’s netting: Indigo Heron’s sales invoice to Green Otter is INV-0042 for £1,800 (£1,500 + £300 VAT). Green Otter’s bill to Indigo Heron is BILL-0017 for £2,400 (£2,000 + £400 VAT). Cash difference: £600, received by BACS on 31 May.
The Xero state before
The bank feed shows one unreconciled line:
Date Description Spent Received Status
31 May 2026 GREEN OTTER CONSULT BACS REF £600.00 Unreconciled
The Accounts Receivable ledger shows INV-0042 awaiting payment at £1,800. The Accounts Payable ledger shows BILL-0017 awaiting payment at £2,400. The chart of accounts has a “Contra Clearing” current liability account (code 820, payments enabled).
What TheBookkeeper.ai does
- Detects the new unreconciled line and cross-references open invoices and bills for “Green Otter Consulting.”
- Identifies contra pattern: debtor balance £1,800, creditor balance £2,400, cash receipt £600 (= difference).
- Confirms clearing account 820 exists and has a zero balance.
- Posts payment against INV-0042: £1,800 to account 820 on 31 May. INV-0042 status → Paid.
- Posts payment against BILL-0017: £1,800 to account 820 on 31 May. Account 820 balance → £0. BILL-0017 outstanding balance → £600.
- Matches the £600 bank receipt to the remaining balance on BILL-0017. Bank line → Reconciled. BILL-0017 status → Paid.
- Writes narration on all three postings: “Contra arrangement with Green Otter Consulting, May 2026. INV-0042 netted against BILL-0017; £600 BACS received 31 May.”
The Xero state after
The bank line shows reconciled, matched against BILL-0017 at £600. INV-0042 shows paid at £1,800 (no cash movement, settled via contra). BILL-0017 shows paid at £2,400 (£1,800 via contra, £600 via BACS). Account 820 balance is zero. The debtors ledger and creditors ledger are both clean.
What it flagged
Nothing in this case — the amounts netted cleanly and the clearing account already existed. If account 820 had not existed, TheBookkeeper.ai would have paused before step 4 and flagged: “No contra clearing account found in chart of accounts. Propose creating account 820 (Contra Clearing, current liability, payments enabled) before proceeding. Confirm?”
One tap. Then it continues.
Takeaway
- A contra entry requires a two-leg journal through a clearing account — one leg settles the sales invoice, the other settles an equal portion of the purchase bill, and the clearing account nets to zero.
- Xero’s bank feed and JAX cannot produce this posting. They see only the cash movement, not the non-cash leg.
- Bank rules make the problem worse: they reconcile the cash line against a general code and leave both the invoice and the bill open, so the ledger looks clean in the bank feed and is wrong everywhere else.
- The correct method — documented in Xero Central — involves a clearing account and manual payment entries against each document. It works, but it is a four- to five-step manual process that most bank rules and rule-based tools cannot execute.
- For a more detailed look at where Xero’s bank rules reach their limit, see Xero Bank Rules vs AI: Which Should You Trust? and Why Rule-Based Reconciliation Breaks on Real Businesses.
Get on the list
If your books include a supplier who is also a customer — and month-end involves a manual clearing-account routine you’d rather not own — we’d like to see them. Get on the waitlist and we’ll handle the contra for you.
Sources:
Frequently asked questions
Do I need to set up a special account in Xero before posting a contra?
Yes. You need a clearing account — typically a current liability account with payments enabled — before you can post the non-cash leg of a contra. Without it, there is nowhere to code the offsetting payment entries, and Xero will not let you mark the invoice or bill as settled without a valid account to post against.
Will a Xero bank rule automatically handle a supplier who is also a customer?
No. A bank rule can categorise the cash receipt and tick the bank line as reconciled, but it has no visibility into open invoices or bills. Both the sales invoice and the purchase bill remain unpaid on the ledger. Your debtors and creditors balances will be wrong even though the bank feed looks clean.
What happens to VAT when two businesses agree to net their invoices?
Each invoice retains its own VAT treatment and tax point — the date the invoice was raised, not the date of the cash movement or the netting agreement. If the two invoices fall in different VAT periods, you may need to account for them separately on your VAT return. Seek confirmation from your accountant if the amounts or periods differ significantly.
Can I use Xero's 'Apply to invoice' feature instead of a clearing account for a contra?
Xero's built-in offset tool (Apply a sales invoice to a bill) can work for straightforward contras where the same contact has matching balances. The clearing-account method is more reliable when amounts don't net exactly or when you need a clear audit trail showing both legs of the posting separately — which most accountants prefer at year-end.
How do I know if a contra has been posted incorrectly in my Xero file?
Check the contact record for the supplier-customer: if the sales invoice and purchase bill both show as outstanding after you have received or sent only the difference in cash, the contra has not been posted correctly. Also review your Aged Receivables and Aged Payables reports — clean contras leave zero balances on both sides for that contact.
Is there a way to get contras handled automatically without doing the clearing-account steps myself each month?
Rule-based reconciliation tools cannot construct the two-leg journal a contra requires. TheBookkeeper.ai detects the contra pattern from your bank feed and open documents, posts both clearing-account legs, and matches the cash — so your ledger is clean without you touching the clearing account. You review the result rather than build it.
Want this running on your Xero?
We're running a private beta for UK Xero users. Get on the list and we'll show you what reconciled-by-morning looks like on your books.