Skip to main content
Back to Resources
Guides

How to Connect Xero to Claude AI: The Complete Guide

Franco 7 min read

Xero holds your financial data. Claude can reason about it, pull reports, create invoices and answer questions in plain language. The bridge between them is MCP.

MCP (Model Context Protocol) is an open standard that lets AI assistants connect to external tools and data sources. Xero publishes its own MCP tools for connecting Claude to Xero. ELab AI also provides a hosted integration for teams that need several organisations available in one session.

This guide covers both. We'll start with Xero's own setup, then explain how a hosted multi-organisation connection works.

What MCP Does for Accounting

Without MCP, getting financial data into Claude means exporting CSV files, copying numbers from Xero reports or describing your data in text. MCP changes this. Claude connects directly to Xero's API and can:

  • Pull profit and loss, balance sheet and trial balance reports
  • Query invoices, bills, contacts and bank transactions
  • Create invoices and draft bills
  • Post manual journals
  • Manage contacts and payment records
  • Run aged receivables and payables reports

The data is always live. No exports. No stale spreadsheets.

Setting Up the Official Xero MCP

The official Xero MCP server is published by XeroAPI as an npm package. It supports 60+ commands covering contacts, invoices, payments, journals, bank transactions and financial reports.

Prerequisites

You need Node.js v18 or later and a Claude Desktop or Claude Cowork subscription. The MCP server runs locally on your machine as a background process that Claude communicates with.

Step 1: Get Your Xero Credentials

The official MCP server uses OAuth2 bearer token authentication. You'll need a Xero app registered in the Xero Developer Portal with the appropriate scopes. For apps created after March 2026, Xero requires granular scopes rather than the broad accounting.transactions scope. The key ones are:

  • accounting.contacts for customer and supplier data
  • accounting.invoices for invoice management
  • accounting.payments for payment records
  • accounting.banktransactions for bank feeds
  • accounting.reports.balancesheet.read, accounting.reports.profitandloss.read, accounting.reports.trialbalance.read for financial reports

Step 2: Configure Claude Desktop

Open Claude Desktop, go to Settings, then Developer, then Edit Config. This opens claude_desktop_config.json. Add the Xero MCP server to the mcpServers block:

{
  "mcpServers": {
    "xero": {
      "command": "npx",
      "args": ["-y", "@xeroapi/xero-mcp-server@latest"],
      "env": {
        "XERO_CLIENT_BEARER_TOKEN": "your-access-token-here"
      }
    }
  }
}

Save the file, fully quit Claude Desktop (right-click dock icon, Quit) and relaunch. A simple close and reopen isn't enough for new MCP servers to load.

Step 3: Enable the Connector

Open a new chat, click the + button, go to Connectors and enable Xero. You should now be able to ask Claude about your Xero data.

The Single-Entity Limitation

The official MCP connects to one Xero organisation per session. If you run multiple entities (and many businesses do), you need to go to Settings, then Connectors, reconnect and select the other organisation through the Xero OAuth picker. Every time you switch.

For a bookkeeper managing three entities, this is manageable. For a property manager with 12 SPVs or an investment firm with 10 fund entities, it's a blocker. You can't search across organisations without disconnecting and reconnecting each time.

Multi-Entity Access with ELab AI's MCP Integration for Xero

ELab AI built an MCP integration specifically for businesses running multiple Xero organisations. It connects all your entities from a single Claude session.

What's Different

The core Xero API coverage is the same. What changes is the infrastructure around it:

Multi-entity in one session. Authenticate once with an account that has access across your entities (advisor-level or admin). All organisations are accessible without switching connectors.

Hosted infrastructure. The MCP server runs on managed infrastructure, not on your local machine. Token refresh is automatic. You don't need to manage Node.js processes or keep a terminal running.

Stronger search and Xero Projects. Invoice and credit note search supports filtering by reference, status and date range, with larger result pages when you need them. Xero Projects can be listed, and completed projects closed, where Projects access is enabled.

Governed access. Access is limited to approved users, client environments stay separated, and write actions are logged.

Audit trail. Every write operation logs the timestamp, the user who initiated it and what changed. This matters for compliance: when Claude creates an invoice or posts a journal, the audit trail shows who asked for it.

How the Auth Works

ELab AI's MCP uses Xero's OAuth PKCE flow. The authenticating user needs advisor-level access across the entities you want to connect. Standard access works for single-entity setups but won't cover multiple orgs.

Once authenticated, the refresh token rotates automatically. You authenticate once and the connection persists. No 30-minute token expiry to manage.

When to Use Which

If you run a single Xero organisation and want to try AI-powered accounting, the official Xero MCP is a good starting point. It's free and covers the full Xero API.

If you run multiple Xero organisations and need access across them, ELab AI's MCP integration for Xero is built for that. It adds multi-organisation access, hosted infrastructure, stronger invoice and credit note search and governed access on top of the same Xero API coverage.

The decision comes down to entity count. One org: start with the official MCP. Multiple orgs: you'll hit the single-entity wall quickly and want multi-entity access from the start.

What You Can Do Once Connected

Regardless of which MCP you use, once Xero is connected to Claude, accounting work changes. Instead of navigating the Xero UI, exporting reports and building spreadsheets, you describe what you need:

"Pull the aged receivables over 60 days across all entities."

"Create an invoice for Knight Corp, $4,500 for advisory services, due in 14 days."

"Show me the P&L for the last quarter and compare it to the same period last year."

"Post a management fee journal of $2,000 from Entity A to Entity B."

Claude executes the operations through the Xero API and returns the results. For read operations, that's instant. For write operations, the data goes straight into Xero. No copy-paste. No re-keying.

The real shift is in how finance teams spend their time. The manual data entry and report generation that fills hours each week is handled by Claude. The thinking, the analysis, the decisions that require human judgement still sit with the people who understand the business.

Get Started

Read more about managing multiple Xero organisations with AI or go straight to the MCP integration for Xero to see how it works.

Not using Claude? The same hosted MCP connects to ChatGPT and to Microsoft 365 Copilot through Copilot Studio.

Xero MCPXero AI IntegrationXero ClaudeMCPAccounting AutomationMulti Entity Xero

Frequently Asked Questions

Yes. Xero publishes it as an npm package and it covers the full Xero API. You run it locally on your own machine, so the only cost is the time to set it up and keep it running.

Both. Claude can create invoices, draft bills, post manual journals and manage contacts and payments, alongside read operations like pulling reports and querying transactions. Every write goes straight into Xero through the API.

For the official Xero MCP, some technical comfort helps: you install Node.js, register a Xero app and edit a config file. ELab AI's hosted MCP integration removes that setup, so you authenticate once and start working.

Not with the official MCP. It connects to one organisation per session, and you reconnect through the Xero picker to switch. ELab AI's MCP integration for Xero connects every organisation you have authorised at once, so you can search and work across them without switching.

The connection uses Xero's own OAuth, and data is accessed live rather than copied out. ELab AI's hosted version adds automatic token rotation and an audit trail that logs every write operation, including who initiated it and what changed.

Choose the Right Starting Point for Your Business

Tell us what you'd like your business to do better, or where you're getting stuck with AI. A few sentences are enough.

From ELab AI

In the Loop Newsletter

Model releases worth paying attention to, practical lessons from client work and useful ways to apply AI inside your business.