> This page is for Developer.

> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://docs.bigcommerce.com/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://docs.bigcommerce.com/_mcp/server.

# Locales Configuration

This overview explains how to manage locales using the [GraphQL Admin API](/developer/api-reference/graphql/account/overview).

## Introduction

The BigCommerce GraphQL Admin API enables developers to manage languages across different channels. By accessing locale data and related configurations, developers can more easily localize headless storefronts.

## Getting started

With the GraphQL Admin API, merchants can add, update, or remove locales for each sales channel, change locale status, and set a locale as the default. Below are examples of GraphQL queries and mutations for retrieving and managing locale settings.

Each storefront can have up to 5 locales.

## Example requests

This section provides examples of GraphQL Admin API queries and mutations that demonstrate how to manage locales, along with the required HTTP configuration.

**`GraphQL Admin API HTTP configuration`**

```http title="GraphQL Admin API HTTP configuration" showLineNumbers={false}
POST https://api.bigcommerce.com/stores/{{store_hash}}/graphql
X-Auth-Token: {{access_token}}
Accept: application/json
Content-Type: application/json
```

### Query locales supported by the platform

This query returns a static list of all locales currently supported by the platform.

#### Request

**`Example query: Get locales supported by the platform`**

```graphql title="Example query: Get locales supported by the platform"
query {
  i18n {
    supportedLocales {
        edges {
            node {
                code
                englishName
                hasBuiltInTranslations
            }
        }
      }
    }
  }
```

#### Response

**`Example query: Get locales supported by the platform`**

```json title="Example query: Get locales supported by the platform" showLineNumbers={false}
     {
  "data": {
    "i18n": {
      "supportedLocales": [
        {
          "code": "ua",
          "englishName": "Ukrainian",
          "hasBuiltInTranslations": false
        },
        {
          "code": "en-US",
          "englishName": "English (United States)",
          "hasBuiltInTranslations": true
        },
        {
          "code": "en-UK",
          "englishName": "English (United Kingdom)",
          "hasBuiltInTranslations": true
        },
        {
          "code": "fr",
          "englishName": "French",
          "hasBuiltInTranslations": true
        }
      ]
    }
  }
```

### Query channel locales

The following query returns channel locales.

#### Request

**`Example query: Get locales`**

```graphql title="Example query: Get locales"
query {
  store {
    locales(input: { channelId: "bc/store/channel/1"}) {
      edges {
        node {
          code
          status
          isDefault
        }
      }
    }
  }
}
```

#### Response

**`Example query: Get locales`**

```json title="Example query: Get locales"
 {
  "data": {
    "store": {
      "locales": {
        "edges": [
          {
            "node": {
              "code": "en",
              "status": "INACTIVE",
              "isDefault": true
            }
          }
        ]
      }
    }
  }
}
```

### Add a locale

The following mutation adds a locale.

#### Request

**`Example query: Add a locale`**

```graphql title="Example query: Add a locale"
mutation {
  locale {
     addLocale(input: {
        channelId: "bc/store/channel/1",
        code: "fr",
        status: INACTIVE
        }) {
              locale {
                  code
                  status
            }
              errors {
                  ... on Error {
                  message
                        }
                    }
                }
            }
        }
```

#### Response

**`Example query: Add a locale`**

```json title="Example query: Add a locale"
 {
  "data": {
    "locales": {
      "addLocale": {
        "locale": {
          "code": "fr",
          "status": "INACTIVE",
          "isDefault": false
          },
        "errors": []
      }
    }
  }
}
```

### Update a locale

The following mutation updates a channel's locale.

#### Request

**`Example query: Update a locale`**

```graphql title="Example query: Update a locale"
  mutation {
   locale {
      updateLocale(input: {
         channelId: "bc/store/channel/1",
         code: "fr",
         status: ACTIVE,
         isDefault: false
         }) {
               locale {
                   code
                   status
                   isDefault
             }
               errors {
                   ... on Error {
                       message
                         }
                     }
                 }
             }
         }
```

#### Response

**`Example query: Update a locale`**

```json title="Example query: Update a locale"
 {
  "data": {
    "locale": {
      "updateLocale": {
        "locale": {
          "code": "fr",
          "status": "ACTIVE",
          "isDefault": false
          },
        "errors": []
      }
    }
  }
}
```

### Delete a locale

The following mutation deletes a channel's locale.

#### Request

**`Example query: Delete a locale`**

```graphql title="Example query: Delete a locale"
 mutation {
   locale {
      deleteLocale(input: {
         channelId: "bc/store/channel/1",
         code: "fr",
         }) {
               code
               errors {
                   ... on Error {
                   message
                         }
                     }
                 }
             }
         }
```

#### Response

**`Example query: Delete a locale`**

```json title="Example query: Delete a locale"
  {
  "data": {
    "locale": {
      "deleteLocale": {
        "code": "fr",
        "errors": []
      }
    }
  }
}
```