> ## Documentation Index
> Fetch the complete documentation index at: https://docs.francis.app/llms.txt
> Use this file to discover all available pages before exploring further.

# Xero

> How to connect and configure Xero.

## Overview

By connecting your Xero instance to Francis, you can import and consolidate your actuals. Once integrated, Francis makes your chart of accounts accessible via the **Mappings** view in your model. From there, you can define custom mappings of Xero accounts to corresponding line items in your financial model.

## Configuration

To set up the Xero integration, go to **Settings > Integrations > Xero**. After enabling this option, a prompt will appear asking you to authorize Francis as an application in your Xero account. Completing this authorization step ensures that Francis can securely access journal entries from your Xero environment.

### Account categories

For Francis to process your Xero data correctly, each general ledger account must have a valid account category. If you haven’t assigned these categories review your Xero settings and ensure that each account is properly classified.

### Currency conversion

Imported transactions from Xero can automatically convert from their base currency into a chosen target currency. To enable this feature, open the **Currency Conversion** section of your Xero connection settings in Francis and toggle **Enable currency conversion**. You can use either market rates or custom rates for your conversions.

### Dimensions

<Info>
  Dimensional planning for Xero is coming soon. If you have questions about this upcoming feature, feel free to reach out at [support@francis.app](mailto:support@francis.app).
</Info>

## Adjustments

Francis applies several adjustments to ensure that imported data is aligned with best practices and supports clear financial analysis.

<Tabs>
  <Tab title="Number convention">
    Francis follows a consistent convention for interpreting accounts:

    * **Positive (+):** Income (I), Asset (A), Liability (L), and Equity (EQ)

    * **Negative (-):** Expense (EX)

    This standardization simplifies comparisons and makes reporting easier. Because Francis determines each account’s classification based on your asset range settings, verify that your configuration is correct before proceeding.
  </Tab>

  <Tab title="Balance sheet">
    Francis presents balance sheet values as accumulated amounts at a specific point in time, rather than as movements over a period. This approach requires an adjustment upon import to ensure your balance sheet data aligns with common reporting conventions.
  </Tab>
</Tabs>

### Retained earnings

<iframe width="720" height="467" src="https://www.loom.com/embed/82c6f24084364b4dbbddbabd504ca943?sid=531cd2c5-b672-48a5-83c1-95d42db54f57" frameborder="0" webkitallowfullscreen mozallowfullscreen allowfullscreen />

When importing your chart of accounts from Xero, Francis currently doesn't automatically include your retained earnings account. Therefore, you'll need to manually calculate retained earnings on your balance sheet for all entities using Xero.

<Info>
  Including retained earnings for Xero is coming soon. If you have questions about this upcoming feature, feel free to reach out at [support@francis.app](mailto:support@francis.app).
</Info>

To calculate retained earnings, add net profit (or loss) to the beginning retained earnings balance:

```typescript theme={null}
// Example
= "Retained earnings"[-1] + "Net profit"[0]
```

If currency conversion is enabled on your Xero connection, the retained earnings formula must account for differences between average and closing exchange rates:

1. **Retained earnings (starting value):** Adjust to the new month’s closing exchange rate.

2. **Net profit (current month):** Convert from the average exchange rate to the closing rate.

```typescript theme={null}
// Currency conversion example
= "Retained earnings"[-1] / "Exchange rate - closing"[-1] * "Exchange rate - closing"[0] 
+ "Net profit"[0] / "Exchange rate - avg"[0] * "Exchange rate - closing"[0]
```
