# Import Inventory Items into Xero

- Author: SimpleBankConvert (https://simplebankconvert.com)
- Published: 2026-10-17
- Category: Invoices, bills and lists
- Canonical: https://simplebankconvert.com/blog/import-inventory-items-into-xero

> How to import inventory items into Xero with its items template: codes, sales and purchase prices, accounts and tracked items with opening quantities.
To import inventory items into Xero, download the items template, fill one row per item with a unique code, a name, sales and purchase prices and their accounts, and import the file. Tracked items also need an inventory asset account and a cost of goods sold account. Opening quantities come from a dated purchase afterward.

## What goes in each column of the Xero items template?

Each row of the Xero items template describes one item from two sides: what you sell it for and what you buy it for. The sales side carries a description, a unit price, an account and a tax rate. The purchase side carries its own description, unit price, account and tax rate. Only the item code is compulsory.

Xero's published [Accounting API specification for items](https://github.com/XeroAPI/Xero-OpenAPI/blob/master/xero_accounting.yaml) lists the same fields the template is built around. It describes a code, a name, a sales description, a purchase description, and a sales and purchase block that each hold a unit price, an account code and a tax type. The specification marks the code as the one required field.

### An example items sheet

The column labels below describe the content and are not Xero's exact header names. Keep the header row exactly as it comes in the template you download. The values are examples.

| Code | Name | Sales price | Sales account | Purchase price | Purchase account | Inventory asset account | Tracked |
| --- | --- | --- | --- | --- | --- | --- | --- |
| SVC-INSTALL | Installation, per hour | 75.00 | 200 Sales | | | | No |
| LAMP-OAK | Oak desk lamp | 64.00 | 200 Sales | 22.50 | 310 Cost of Goods Sold | 630 Inventory | Yes |

Accounts are given by code, the number in your chart of accounts, not by name. For a tracked item, the purchase account column carries the cost of goods sold account. Check every account code against your chart of accounts before you upload.

## Item codes Xero will accept on import

An item code in Xero can be up to 30 characters, and it must be unique, because it is the key Xero uses to find the item. Xero's API specification sets that 30-character limit, and caps the name at 50 characters and each description at 4,000.

Codes are what staff type on invoices and bills, so short and readable beats long and exact. 
Pick a pattern and stick to it, such as a category prefix and a short product word: `LAMP-OAK`, `LAMP-WAL`, `SHADE-LIN`. Avoid codes that differ only by a letter O and a zero, or by case. Because the code is how Xero tells items apart, a second file that reuses a code is talking about the same item, not a new one. Check the code column hardest before every upload, and keep an export of the current list before you change anything.

## Tracked inventory items and their two extra accounts

A tracked item is one whose quantity and value Xero counts. Xero's API specification says an item is tracked when two accounts are set: an inventory asset account, which must be of the inventory type, and a cost of goods sold account on the purchase side. Leave either blank and the item imports as untracked.

For a tracked item, purchases go to the inventory asset account rather than an expense account, and each sale moves the cost from that asset to cost of goods sold. The specification notes that the ordinary purchase account does not apply to the purchase side of a tracked item, because the asset account takes its place. Create both accounts in the chart of accounts before you import, and put their codes in the template.

## How do opening quantities reach a tracked Xero item?

A tracked item's quantity and value build up from the transactions that use it, not from a number typed into the item. Xero's API specification says the value of stock on hand is calculated using average cost. So the opening count goes in as a dated purchase of each item at its cost, made after the items are imported.

A common approach is a single bill dated the day before you start trading in Xero, made out to a contact such as "Opening stock", with one line per tracked item showing the counted quantity and the unit cost. That bill puts the quantities and their value onto the inventory asset account. It also creates a payable you do not really owe, which has to be cleared against an equity or opening balance account. Agree that clearing step with your accountant before you post it, because it decides where the opening stock value sits on the balance sheet.

### Counting first

The quantity on that bill should come from a physical count on or near the start date. Any sale recorded in Xero before the opening bill is dated draws on stock Xero thinks you do not have, which throws out the average cost of every later sale.

## Untracked items when nobody counts the stock

Leave an item untracked when no one will count it. An untracked item still fills in prices, descriptions and accounts on invoices and bills, which is most of the time saved. It just posts each purchase straight to an expense account, with no quantity on hand to keep right.

Untracked suits services, made-to-order goods and supplies bought for a job. Tracked suits stock you hold and sell from a shelf, where a wrong count costs money. A tracked item that nobody counts is worse than an untracked one, because its quantity and value drift away from what is on the shelf.

Items are the start of the sales side. Customer payments against those sales come next, covered in [importing payments into Xero](/blog/import-payments-into-xero). If a till system feeds a QuickBooks Online file instead, [importing POS sales into QuickBooks Online](/blog/import-pos-sales-into-quickbooks-online) covers that setup, and [setting up QuickBooks Online from bank statements](/blog/set-up-quickbooks-online-from-bank-statements) covers starting a new file from statement history. For Xero, [SimpleBankConvert](/) is being built to turn a PDF bank statement into a CSV laid out for Xero's statement import; [Get started](/get-started) adds you to the waiting list.
