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

# Categories

> Categories are a simple way to classify what your spending and income is for, independently of the GL account it posts to.

Categories are a simple way to classify what your spending and income is *for*, independently of the GL account it posts to. Where the chart of accounts answers *"which ledger account?"*, a category answers *"what kind of activity?"* — Operating Expenses, Payroll, Rent & Utilities, Marketing, and so on. You tag expenses and bill lines with a category so that later you can group, filter and report on spending by the buckets that make sense to your business.

**You'll find this at:** `/accounting/categories` — in the left navigation under **Accounting → Categories**.

> 📷 *Screenshot: Categories list showing the built-in defaults plus any custom categories — to be added.*

***

## What categories classify

A category is an **expense/income classification** that you attach to transactions:

* **Expenses** carry a category, so you can see, for example, how much went to *Marketing* this quarter.
* **Bill lines** carry a category, so each line of a supplier bill can be classified separately.

Categories are organised as a **tree** — a category can have a parent, letting you build groupings such as *Operating Expenses → Office Supplies*. They also optionally carry **default GL accounts** so that picking a category can pre-fill the expense or income account on a transaction.

> **Categories vs. the chart of accounts.** A category is a *reporting/classification* label; it is not itself a ledger account. The actual debit and credit still land on real accounts. The optional **default accounts** on a category are just a convenience that suggests the right ledger account when you choose that category.

***

## Multi-business note

Categories are stored **per accounting book**. Each business (book) has its own category list. Switch the active business with the business switcher before adding or editing categories — you only see and affect the current book's categories. The built-in defaults (below) appear in every book.

***

## Built-in default categories

Every book comes with ten ready-to-use categories so you can start classifying immediately without setting anything up:

| Category                  | What it covers                            |
| ------------------------- | ----------------------------------------- |
| **Operating Expenses**    | Day-to-day business expenses              |
| **Payroll**               | Salaries, wages, and benefits             |
| **Rent & Utilities**      | Office rent, electricity, water, internet |
| **Office Supplies**       | Stationery, equipment, consumables        |
| **Travel & Transport**    | Business travel, fuel, transport          |
| **Marketing**             | Advertising, promotions, branding         |
| **Professional Services** | Legal, accounting, consulting fees        |
| **Insurance**             | Business and employee insurance           |
| **Maintenance**           | Repairs and maintenance costs             |
| **Miscellaneous**         | Other uncategorized expenses              |

These **system default categories cannot be edited or deleted** — if you try, Hitaji blocks it with *"System default categories cannot be edited / deleted"*. They are always active and always appear at the top of the list. You can, of course, add your own categories alongside them.

> A default category only becomes a "real" stored record the first time it is actually used on a transaction; until then it lives as a built-in. This is transparent to you — it simply works.

***

## Creating a category

1. Go to **Accounting → Categories** (`/accounting/categories`).
2. Click **Add Category** (or the equivalent create action).
3. Fill in the fields below.
4. Save.

> 📷 *Screenshot: Create-category form with name, parent, and default-account fields — to be added.*

### Fields

| Field                       | Required | Notes                                                                                                                               |
| --------------------------- | -------- | ----------------------------------------------------------------------------------------------------------------------------------- |
| **Name**                    | Yes      | Must be **unique within the book** (case-insensitive), and must not clash with a built-in default name. Max 255 characters.         |
| **Description**             | No       | Free text describing what the category is for.                                                                                      |
| **Parent category**         | No       | Choose an existing category to nest this one under it. A category cannot be its own parent.                                         |
| **Default expense account** | No       | A GL account of type **Expense** in this book. Suggested as the expense account when you classify a transaction with this category. |
| **Default income account**  | No       | A GL account of type **Income** in this book. Suggested as the income account for income classified here.                           |
| **Sort order**              | No       | Controls display order. If you leave it blank, Hitaji assigns the next number automatically.                                        |
| **Active**                  | No       | New categories are active by default. Inactive categories are hidden from pickers but keep their history.                           |

### Validation you may hit

* **Duplicate name** — *"Category with name '…' already exists"*. Names must be unique within the book (and cannot duplicate a default).
* **Bad parent** — *"Parent category not found"* if the parent does not exist in this book, or *"Category cannot be its own parent"*.
* **Wrong account type** — a default expense account must be an **Expense** account, and a default income account must be an **Income** account, both belonging to the current book. Otherwise the save is rejected.

***

## Editing a category

Open a category and change its name, description, parent, default accounts, sort order or active flag. The same uniqueness and account-type rules apply as on create. Remember: **the ten built-in defaults cannot be edited.**

***

## Deleting a category

Categories are **soft-deleted** (hidden, not physically removed) so historical transactions keep their classification. Before a category can be deleted, Hitaji runs three safety checks and blocks deletion if any fail:

1. **It is a built-in default** — defaults can never be deleted.
2. **It has child categories** — *"Cannot delete category with child categories. Delete children first."* Remove or re-parent the children, then delete.
3. **It is in use** — if the category is used on any expense or bill line, deletion is blocked with a count, e.g. *"Cannot delete category that is used in 4 expenses…"*. Re-categorise those transactions first.

This guarantees you can never orphan a transaction or break the category tree by deleting.

***

## Access & permissions

* **Viewing** categories requires the `accounting:read` scope.
* Creating, editing, and deleting categories is available to users with accounting write access in the book.

***

## Related

* [Customers & Vendors (Contacts)](/accounting/user/masters/contacts)
* [Tax codes](/accounting/user/masters/taxes)
* [Withholding tax](/accounting/user/masters/withholding-tax)
* [Payment terms](/accounting/user/masters/payment-terms)
