The clean way to get Shopify COGS into Xero or QuickBooks is a monthly journal entry: debit Cost of Goods Sold, credit Inventory, for what the units you shipped that period actually cost. Sales connectors move revenue and fees automatically, but none of them know your product costs, so the cost side of your P&L is on you.
This is the gap behind a familiar month-end experience: sales are in the books to the cent, and gross profit is still a shrug. This guide explains the journal, the one accounting decision you must make first, where the number should come from, and the mistakes that quietly break the books.
Why Your Connector Stops at Revenue
Connector apps and the native Shopify integrations for Xero and QuickBooks are good at the revenue side: orders, refunds, gateway fees, payouts that match the bank feed. Everything they need for that lives inside Shopify.
The cost side is different. What the sold units cost depends on which purchase they came from, what you paid, and (for imported stock) the freight and duty that should be allocated into each unit. None of that lives in Shopify, so no connector can post it. The result is a P&L where revenue updates daily and COGS is either missing, guessed quarterly, or trued up once a year at tax time, months after the decisions it should have informed.
The Journal That Closes the Gap
The entry itself is two lines. If the units you shipped in July cost $8,412.60:
| Account | Debit | Credit |
|---|---|---|
| Cost of Goods Sold (P&L) | $8,412.60 | |
| Inventory (Balance Sheet) | $8,412.60 |
It moves cost from the balance sheet (where it sat as stock) to the P&L (where it belongs once the stock is sold), matched against the same period's revenue. Post it monthly and three things become true at once: your gross margin is real every month, your Inventory account tracks what you actually hold, and year end stops being an archaeology project.
Two lines. The entire difficulty is the number on them, and one decision that has to come first.
Perpetual vs Periodic: Pick One, Never Both
Before any journal is posted, you and your bookkeeper need to agree how stock purchases are treated, because the journal only makes sense under one of the two treatments:
| Perpetual (recommended) | Periodic | |
|---|---|---|
| Buying stock posts to | Inventory (asset) | Purchases (expense) |
| COGS appears | Monthly, via the journal above | At period end, from a stock count |
| Gross margin during the year | Accurate every month | Distorted by every big stock buy |
| Works with the COGS journal | Yes, it is the point | No. Posting both double-counts the cost |
The worst of both worlds is mixing them: purchases expensed to a Purchases account and a COGS journal posted on top. Every dollar of stock hits the P&L twice, margin collapses on paper, and someone spends a billable afternoon finding out why.
Where the COGS Number Comes From
On perpetual treatment, the journal needs the actual cost of the actual units shipped in the period. That requires a cost ledger: FIFO cost layers (or a proper moving average) that record each receipt at what it cost, including landed cost for imported stock, and deplete as orders ship.
What does not work as a source: Shopify's Cost per item field (a single current value that rewrites history whenever it is edited), a percent-of-revenue estimate (your auditor and your margin decisions deserve better), or last year's ratio (supplier prices moved).
What Good Looks Like: Finance-Grade Inventory Truth
The end state to aim for is finance-grade inventory truth: landed cost allocated into every unit, FIFO cost layers behind every sale, a ready-to-post COGS journal each month, and an Inventory balance that matches the warehouse. Not more inventory tracking. Numbers your accountant can post without asking where they came from.
3 Mistakes That Break the Books
- Double-counting. The freight bill coded to a Direct Costs expense account and folded into the landed cost that reaches the COGS journal. Each capitalisable cost belongs in Inventory once, and reaches the P&L only through the journal.
- Capitalising recoverable tax. Import GST/VAT is claimed back on your next return, so it is not a cost of the goods. Fold it into landed cost and your inventory, COGS and margins all overstate by roughly the tax rate, and the claim never reaches your return.
- Posting COGS against a drifted inventory balance. If the units in the ledger no longer match the shelf, the drift needs to be counted and costed (as shrinkage or adjustments) or the Inventory account slowly detaches from reality no matter how good the journal is.
A Month-End Workflow That Takes Minutes
This is the workflow Landara automates, and it is the same workflow you would build by hand:
- Costing runs all month. Landara connects to Shopify and costs every order as it ships, oldest cost layer first, with landed cost folded in for imported stock. Nothing to enter.
- Review the COGS report. Period COGS per SKU, with a full audit trail from every order back to the cost layer and source document behind it. Uncosted sales are flagged, not smoothed over.
- Post the journal. One ready-to-post Dr COGS / Cr Inventory entry for Xero or QuickBooks, using the accounts you mapped once. You review it and post it; Landara never writes to your ledger unasked. Close the period and it locks.
Bookkeepers run this for Shopify clients as a monthly routine: connect once, then each period is a review and a post. The same workflow works across a client list, and every number traces back to a document.
Your revenue has synced itself for years. The month you give COGS the same treatment is the month gross profit becomes a number you check, not a number you defend.
Close This Month With a Real COGS Number
Connect Shopify and Landara costs every order FIFO, then hands you the journal. The 30-day trial covers a full month end before you pay anything.
Try Landara Free