Xero and Looker integration
Xero runs your books; Looker makes sense of them. Connecting the two lets you build live financial dashboards, analyze invoice trends by customer or account, drill into purchase order aging, and reconcile GL accounts against actual warehouse data. Xero exposes invoices, payments, accounts, and contacts through webhooks and polling; Looker models that data for analysis and powers scheduled reports. ml-connector bridges the two with full audit trails and reliable delivery.
What moves between them
Xero invoices, purchase orders, accounts, and payments flow into Looker via ml-connector for financial analysis and reporting. The integration reads from Xero in real-time via webhooks for transactional events (invoices, payments, manual journals) and on a configurable schedule via polling for reference data (accounts, contacts, tracking categories). ml-connector transforms the records to Looker's canonical schema and either ingests them directly via Looker's API or stages them for scheduled delivery to a data warehouse that Looker models. GL accounts and tracking categories are synchronized bidirectionally so Looker dashboards always reference valid GL dimensions. Because Looker is read-only for financial data, ml-connector does not write records back to Xero.
How ml-connector handles it
ml-connector stores Xero OAuth2 credentials (client_id, client_secret, refresh_token) encrypted and automatically refreshes them as the 30-minute access tokens expire. It validates webhook signatures using the Xero-provided webhook signing key, stored separately from the OAuth client secret, and polls Xero for reference data (accounts, contacts) on a daily or weekly schedule. For Looker, ml-connector exchanges OAuth2 credentials for a 1-hour bearer token, caches it, and re-authenticates when the token expires rather than waiting for a 401. Invoices and bills are routed via the Type field (ACCREC vs ACCPAY), and tracking categories are mapped to Looker dashboard filter dimensions. Xero's rate limit of 60 calls per minute per tenant is respected with adaptive backoff; if a request hits the 5 concurrent limit, ml-connector queues and retries. Looker's 5000-row query limit means large datasets (all invoices for a year) are paginated and either staged in a warehouse first or delivered via Scheduled Plans to S3 or email. Every webhook and poll carries a job ID for deduplication, and full audit trails track source record ID, transformation, delivery status, and timestamp.
A real-world example
A mid-sized professional services firm uses Xero for accounting and runs Looker on top of their data warehouse for business intelligence. Finance team needs live dashboards showing revenue by customer and project, invoice aging by GL account, and purchase order spend by department. Before the integration, data was exported from Xero weekly, manually staged in the warehouse, and Looker dashboards refreshed with 7-day lag. With Xero and Looker connected, invoices and payments flow in real-time via webhooks; by Friday afternoon, the revenue dashboard reflects the week's billings, aging is current, and month-end close can start without manual export steps. The finance team now spends 2 hours per month on reconciliation instead of 8, and CFO can pull live GL reports on demand.
What you can do
- Sync Xero invoices and bills to Looker dashboards for revenue and expense analysis by customer, project, and GL account.
- Deliver Xero purchase orders and payments to Looker scheduled plans for spend reporting and aging analysis.
- Map Xero tracking categories to Looker dashboard filters so finance team can drill by cost center, department, or project.
- Receive real-time notifications from Xero webhooks, validate signatures, and poll for reference data on a configurable schedule.
- Handle Xero rate limits, OAuth2 token refresh, Looker's 1-hour token expiry, and audit every record delivery with job ID deduplication.
Questions
- What happens when a Xero webhook arrives but the full record fetch fails?
- ml-connector logs the webhook event with resource ID and status, retries the GET request with exponential backoff, and marks the job for manual replay if the retry limit is exceeded. The audit trail shows exactly where it failed, and the Finance team can troubleshoot by checking the Xero API logs or webhook delivery history.
- Does ml-connector handle Looker's 5000-row query limit and 1-hour token expiry?
- Yes. Large datasets are paginated across multiple Looker queries or staged in a data warehouse first, depending on the Looker instance's permissions and architecture. For token expiry, ml-connector re-authenticates on each 401 response and caches the new token for up to 1 hour, so token refresh happens transparently without job failures.
- How are Xero invoices and bills (both use the same endpoint) kept separate in Looker?
- Xero differentiates invoices and bills via the Type field: ACCREC for customer invoices, ACCPAY for supplier bills. ml-connector maps these to separate Looker explores or model views so dashboards can slice by invoice type, and the GL account dimension ensures bills post to AP accounts and invoices to AR accounts.
Related integrations
More Xero integrations
Other systems that connect to Looker
Connect Xero and Looker
Free to use. Add your credentials, ping your real systems, and see if we fit.
Get started