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

# You Need a Budget

> Sync transactions to a You Need a Budget plan

You Need a Budget syncs bank transactions directly into your plan, keeping your ledger up to date.

## Setup

<Steps>
  <Step title="Connect your You Need a Budget account">
    Click **Add Destination**, select **You Need a Budget**, and sign in. Redbark Sync uses OAuth to connect to your You Need a Budget account.
  </Step>

  <Step title="Select a plan">
    Choose the You Need a Budget plan where transactions should be synced.
  </Step>

  <Step title="Acknowledge the disclosure and save">
    Tick the CDR disclosure checkbox confirming you understand data sent to You Need a Budget leaves Redbark's control and is governed by YNAB's own terms. Account selection happens later when you create a sync, via account mapping.
  </Step>
</Steps>

## Creating a sync

When you create a sync with a You Need a Budget destination, two extra steps are available beyond the standard sync setup:

### Account mapping

You can map each bank account to a different You Need a Budget account within the same plan. For example:

* CommBank transaction account → "Everyday Checking" in You Need a Budget
* CommBank credit card → "Visa Credit Card" in You Need a Budget
* ING savings → "Savings" in You Need a Budget

This lets you sync multiple bank accounts in a single sync, with each one writing to the correct You Need a Budget account.

### Category mapping

You can optionally map bank transaction categories to You Need a Budget categories. If you set up mappings, those transactions will arrive in You Need a Budget with the matching category already applied. Any unmapped categories come through without a category, so you can categorise them in You Need a Budget manually or let You Need a Budget's auto-categorisation handle it.

The bank categories available for mapping are: Bank Fees, Entertainment, Food & Drink, Government & Non-Profit, Home Improvement, Income, Loan Payments, Medical, Merchandise, Personal Care, Rent & Utilities, Services, Transfer In, Transfer Out, Transportation, and Travel.

Not all transactions have a category. See the [transactions API reference](/api-reference/transactions#categories) for details.

The category picker hides categories that are flagged as `hidden` or `deleted` in YNAB, along with YNAB's internal `Credit Card Payments` and `Internal Master Category` groups. Only user-visible categories appear in the picker.

## How it works

On each sync, Redbark Sync:

1. **Fetches transactions**: pulls recent transactions from your connected bank accounts. Pending transactions are excluded by default to avoid duplicates when they later post with updated details. You can enable pending transactions per sync as an [experimental setting](/syncs#include-pending-transactions-experimental); the toggle applies to any banking sync, including YNAB.
2. **Transforms to You Need a Budget format**: maps fields to the You Need a Budget transaction schema (payee, amount in milliunits, memo, and optionally a mapped category).
3. **Routes to accounts**: sends each transaction to the correct You Need a Budget account based on your account mapping. The destination supports both per-account mode (multiple bank accounts mapped to distinct YNAB accounts) and bulk mode (all transactions to a single YNAB accountId set on the destination config).
4. **Creates transactions**: sends new transactions to You Need a Budget in batches of up to 500. Duplicates are automatically skipped using a unique import ID. All transactions, including pending ones if you've enabled that toggle, are written as `cleared`.

<Note>
  **5-year history limit.** You Need a Budget rejects any transaction dated more than 5 years before today. If your sync start date goes back further, Redbark Sync will fetch the full history from your bank but only forward transactions from the last 5 years to You Need a Budget. Older transactions are skipped silently.
</Note>

## Field mapping

Payee and Memo are configurable: for each destination, you can map one Redbark source field to Payee and one to Memo. The UI defaults a new destination to Merchant name → Payee and Description → Memo, and you can change either to Extended Description, Reference, Category, or Subcategory (or leave it blank).

If no mapping is configured at all (destinations created before this feature shipped), Redbark falls back to the legacy combined behaviour: merchant name as payee, and category, description, and extended description (or reference) joined into memo.

| Redbark field                          | You Need a Budget field | Notes                                                                                                                                                                                                                                     |
| -------------------------------------- | ----------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Mapped source (default: Merchant name) | Payee name              | Truncated to 50 characters. Blank if the mapped source has no value, or if no mapping is configured and there's no merchant name.                                                                                                         |
| Amount + Direction                     | Amount                  | Converted to milliunits (amount x 1000). Debits are negative, credits are positive.                                                                                                                                                       |
| Mapped source (default: Description)   | Memo                    | Truncated to 200 characters. With no mapping configured, falls back to the humanized category, description, and extended description (or reference if it duplicates the description) joined with `\|`, dropping blank or duplicate parts. |
| Category                               | Category                | Only set when a category mapping exists for the bank's category code                                                                                                                                                                      |
| Status                                 | Cleared                 | Always set to `cleared`, including pending transactions synced with the include-pending toggle enabled.                                                                                                                                   |
| Date                                   | Date                    | YYYY-MM-DD format. Uses the source account's timezone when available (e.g. `Pacific/Auckland` for NZ accounts), otherwise falls back to the destination's configured timezone (default `Australia/Sydney`).                               |
| Transaction ID                         | Import ID               | SHA-256 hash for deduplication                                                                                                                                                                                                            |

<Info>
  You Need a Budget uses **milliunits** for amounts: multiply the dollar amount by 1000. For example, a \$100.50 debit becomes -100500.
</Info>

## Deduplication

Each transaction is assigned a unique `import_id` derived from the Redbark transaction ID. You Need a Budget uses this to detect and skip duplicate transactions, so you can sync as often as you want without creating duplicates.

## Authentication

You Need a Budget uses OAuth 2.0. Access tokens expire after 2 hours (a YNAB-side constant, not a Redbark guarantee) and are refreshed automatically before each sync. If your You Need a Budget session is revoked, re-authenticate from the [destinations](/destinations) page.

## Rate limits

YNAB enforces a limit of 200 requests per hour per access token. If a sync hits the limit, Redbark surfaces a clear 429 error and the sync fails — try again after the window resets.

## Account remapping

If you change an account mapping to a different YNAB account, Redbark resets the sync's `lastDataAt` and backfills the new resource so it doesn't sit empty.

## Tips

* **New transactions are unapproved**: synced transactions arrive as unapproved in You Need a Budget, so you can review and categorise them as part of your normal workflow.
* **Memo for context**: by default the memo field is your bank's description, giving extra context when categorising. Change the mapping if you'd rather see the category, extended description, or reference there.
* **Plan views**: your synced transactions show up in all You Need a Budget views including your plan, accounts, reports, and age of money.
