# Zucms

## Localization

> Category: Content

---

## Pages

- [Introduction](https://docs.zucms.co/introduction)

### API

- [RESTful API](https://docs.zucms.co/api/rest)
- [Typescript SDK](https://docs.zucms.co/api/typescript)

### Getting Started

- [Quick Start](https://docs.zucms.co/getting-started/quick-start)
- [Core Concepts](https://docs.zucms.co/getting-started/core-concepts)

### Models

- [Overview](https://docs.zucms.co/models/overview)
- [Field Types](https://docs.zucms.co/models/field-types)
- [Relations](https://docs.zucms.co/models/relations)

### Content

- [Working with Entries](https://docs.zucms.co/content/working-with-entries)
- [Localization](https://docs.zucms.co/content/localization)

### Access & Security

- [Roles](https://docs.zucms.co/access-security/roles)
- [Access Policies](https://docs.zucms.co/access-security/access-policies)

### Organization

- [Members & Roles](https://docs.zucms.co/organization/members-roles)
- [Audit Log](https://docs.zucms.co/organization/audit-log)
- [Billing & Plans](https://docs.zucms.co/organization/billing-plans)

---

# Localization

Zucms supports multilingual content through per-field localization. Localizable fields store a separate value for each active locale.

## Enabling i18n

1. Go to **Organization Settings**.
2. Open the **Localization** section.
3. Enable **i18n**.
4. Set a **primary locale** (e.g. `en`).
5. Add the locales you want to support.
6. Save.

The primary locale is the default. If a value is missing for a requested locale, the API falls back to the primary locale.

## Supported locales

Zucms supports 23 locales out of the box:

`ar`, `cs`, `da`, `de`, `en`, `es`, `fi`, `fr`, `hu`, `it`, `ja`, `ko`, `nl`, `no`, `pl`, `pt`, `ro`, `sk`, `sv`, `tr`, `uk`, `zh`

## Making a field localizable

In the **Model Builder**, open a field and enable the **Localizable** toggle. Only `string`, `text`, and `enum` fields can be localized.

Once enabled, the field stores a JSON object keyed by locale instead of a plain value:

```json
{
  "en": "Hello World",
  "de": "Hallo Welt",
  "fr": "Bonjour le monde"
}
```

## Editing localized content

When i18n is active, a locale switcher appears at the top of the content form. Select a locale to edit or view translations for that language. Fields that are not localizable always show the same value regardless of the selected locale.

A flag icon on a field indicates that the current locale has no translation yet, or that a fallback value is being shown.

## Querying localized content via the API

Pass the `locale` query parameter to receive values in a specific language:

```bash
GET /api/models/post/entries?locale=de
```

The API resolves each localizable field to its value in the requested locale. If no value exists for that locale, it returns the primary locale value (fallback behavior).

To disable fallback and receive `null` for missing translations:

```bash
GET /api/models/post/entries?locale=de&localeFallback=false
```
