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

# Categorizing Transactions

> Learn how to organize transactions with categories for better reporting

Categories help you organize transactions for accounting, tax reporting, and financial analysis. This guide covers everything from basic categorization to advanced auto-categorization.

## Why Categorize?

Categorized transactions enable:

* **Better reports** - See spending by category
* **Tax preparation** - Group deductible expenses
* **Financial analysis** - Understand where money goes
* **Cleaner exports** - Professional CSV exports for accountants

## Setting Up Categories

### Default Categories

New accounts include default categories:

| Category | Suggested Use      |
| -------- | ------------------ |
| Income   | Received payments  |
| Expenses | Outgoing payments  |
| Trading  | Exchange activity  |
| Transfer | Internal movements |

### Creating Custom Categories

<Steps>
  <Step title="Go to Categories">
    Navigate to **Settings** → **Categories**.
  </Step>

  <Step title="Click Add Category">
    Click the **Add Category** button.
  </Step>

  <Step title="Name your category">
    Enter a descriptive name:

    * "Client Revenue"
    * "Operating Expenses"
    * "DeFi Yield"

    <Tip>
      Be specific enough to be useful, but not so specific that you have dozens of rarely-used categories.
    </Tip>
  </Step>

  <Step title="Choose a color (optional)">
    Select a color for visual distinction in charts.
  </Step>

  <Step title="Save">
    Click **Create** to add the category.
  </Step>
</Steps>

### Recommended Category Structure

**For Personal Use:**

```
├── Income
│   ├── Salary
│   ├── Freelance
│   └── Investments
├── Expenses
│   ├── Bills
│   ├── Shopping
│   └── Entertainment
├── Savings
└── Transfer
```

**For Business Use:**

```
├── Revenue
│   ├── Product Sales
│   ├── Services
│   └── Other Income
├── Expenses
│   ├── Payroll
│   ├── Software & Tools
│   ├── Marketing
│   └── Operations
├── Capital
│   ├── Equipment
│   └── Investments
└── Internal Transfer
```

## Manual Categorization

### Single Transaction

<Steps>
  <Step title="Open Transactions">
    Click **Transactions** in the sidebar.
  </Step>

  <Step title="Find the transaction">
    Use filters or scroll to find the transaction you want to categorize.
  </Step>

  <Step title="Click the transaction">
    Click to open the transaction details or inline edit.
  </Step>

  <Step title="Select a category">
    Click the category dropdown and choose from your categories.

    <Check>
      The category is saved immediately.
    </Check>
  </Step>
</Steps>

### Bulk Categorization

Categorize multiple transactions at once:

<Steps>
  <Step title="Filter transactions">
    Use filters to show only the transactions you want to categorize:

    * Filter by contact (all from same sender)
    * Filter by date range
    * Filter by uncategorized
  </Step>

  <Step title="Select multiple transactions">
    Check the boxes next to transactions you want to categorize.
  </Step>

  <Step title="Apply category">
    Click **Bulk Actions** → **Set Category** and choose your category.

    <Check>
      All selected transactions are updated.
    </Check>
  </Step>
</Steps>

<Tip>
  Use bulk categorization after filtering by contact—transactions from the same address often share a category.
</Tip>

## Auto-Categorization

Let Chainbook automatically categorize transactions based on patterns.

### How It Works

1. **Learning**: Auto-categorization analyzes your existing categorized transactions
2. **Patterns**: It identifies patterns (e.g., "transactions from address X are usually Revenue")
3. **Applying**: New matching transactions are automatically categorized
4. **Reviewing**: Auto-assigned categories are marked for your review

### Enabling Auto-Categorization

<Steps>
  <Step title="Go to Settings">
    Navigate to **Settings**.
  </Step>

  <Step title="Find Auto-Categorization">
    Locate the **Auto-Categorize** toggle.
  </Step>

  <Step title="Enable it">
    Turn on the toggle.

    <Note>
      Auto-categorization works best after you've manually categorized 50+ transactions to establish patterns.
    </Note>
  </Step>
</Steps>

### Training Auto-Categorization

Improve accuracy by:

1. **Categorizing consistently** - Same type of transaction = same category
2. **Using contacts** - Transactions from contacts are easier to pattern-match
3. **Reviewing suggestions** - Correcting mistakes improves future suggestions
4. **Categorizing diverse examples** - Show the AI different transaction types

### Reviewing Auto-Assigned Categories

Auto-assigned categories show an "auto" indicator:

1. Go to **Transactions**
2. Look for the auto-assignment indicator
3. Review each suggestion
4. Confirm or change as needed

<Warning>
  Always review auto-categorized transactions before relying on them for reports.
</Warning>

### Disabling Auto-Categorization

To turn off:

1. Go to **Settings**
2. Toggle off **Auto-Categorize**

<Note>
  Disabling removes existing auto-assignments. Manually assigned categories remain.
</Note>

## Category Workflows

### New Transaction Workflow

When new transactions sync:

1. **Check notifications** - See new transaction alerts
2. **Review in Transactions** - Sort by date, newest first
3. **Categorize** - Assign categories to new transactions
4. **Verify auto-assignments** - Review any auto-categorized transactions

### Weekly Review Workflow

Maintain clean data with a weekly review:

1. **Filter uncategorized** - Find transactions without categories
2. **Review each** - Assign appropriate categories
3. **Check auto-assignments** - Verify AI suggestions
4. **Add contacts** - Label any new addresses

### Month-End Workflow

Prepare for reporting:

1. **Review all transactions** - Filter by current month
2. **Ensure all categorized** - No uncategorized transactions
3. **Verify accuracy** - Check category assignments make sense
4. **Export** - Download categorized data for accounting

## Using Categories in Reports

### Dashboard Charts

The "Chart by Categories" shows:

* Pie chart of transaction distribution
* Category totals for selected period
* Uncategorized percentage

Use it to:

* Verify categorization completeness
* Spot large expense categories
* Track category trends over time

### Filtered Views

Filter transactions by category:

1. Go to **Transactions**
2. Click the **Category** filter
3. Select a specific category
4. View all transactions in that category

### Exports

Categories appear in CSV exports:

| Date       | Amount | From      | To        | Category |
| ---------- | ------ | --------- | --------- | -------- |
| 2024-01-15 | +1000  | Client A  | My Wallet | Revenue  |
| 2024-01-14 | -50    | My Wallet | Vendor    | Expenses |

Use categorized exports for:

* Accounting software import
* Tax preparation
* Financial analysis

## Troubleshooting

<AccordionGroup>
  <Accordion title="Auto-categorization isn't working well">
    Improve accuracy:

    * Manually categorize at least 50 transactions first
    * Be consistent with categories
    * Use contacts to identify transaction partners
    * Review and correct auto-assignments
  </Accordion>

  <Accordion title="I have too many categories">
    Consolidate by:

    * Merging similar categories
    * Using broader category names
    * Keeping 10-20 categories maximum
    * Using descriptions for specifics instead
  </Accordion>

  <Accordion title="How do I recategorize many transactions?">
    Use bulk categorization:

    1. Filter to find transactions
    2. Select all matching transactions
    3. Apply the new category
  </Accordion>

  <Accordion title="Categories aren't showing in export">
    Ensure:

    * Transactions have categories assigned
    * You're exporting the correct columns
    * CSV viewer is displaying all columns
  </Accordion>
</AccordionGroup>

## Best Practices

<CardGroup cols={2}>
  <Card title="Be Consistent" icon="equals">
    Always use the same category for the same type of transaction.
  </Card>

  <Card title="Keep It Simple" icon="list">
    10-20 categories is usually enough. Too many creates confusion.
  </Card>

  <Card title="Review Regularly" icon="calendar">
    Weekly categorization keeps data clean and current.
  </Card>

  <Card title="Use Descriptions" icon="pen">
    Add transaction descriptions for details that don't fit in categories.
  </Card>
</CardGroup>
