---
title: "How to change the language name text in code blocks"
slug: "how-to-change-the-language-name-text-in-code-blocks"
description: "You would want to keep a constant name, like Example, Sample code, etc., as language name text for code blocks. By default, the respective language name appears in the code blocks. "
tags: ["Customization"]
updated: 2025-12-29T08:59:23Z
published: 2026-01-31T09:30:11Z
---

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

# How to change the language name text in code blocks

To maintain consistency and enable ease of use, designate a standard name such as "Example" or "Sample code" for code blocks. By default, the language name is displayed within these blocks. To modify the language name within code blocks, utilize the following workaround:

> [!NOTE]
> ** NOTE
> 
> This action would change the language name in all the code blocks in your knowledge base.

### Solution

1. Navigate to **Settings** (<nor class="fa-solid fa-gear" data-tomark-pass=""></nor>) > **Knowledge base site** > **Site customization** > **Custom CSS & JavaScript** in the Knowledge base portal.

![Site customization options including CSS, JavaScript, and theme settings for a knowledge base.](https://cdn.document360.io/860f9f88-412e-4570-8222-d5bf2f4b7dd1/Images/Documentation/Custom%20css%20&amp;%20js.png)
2. From the left navigation pane, click on the **CSS** tab and paste the following CSS snippet:

```css
div.code-toolbar>.toolbar .toolbar-item:first-child {
    visibility: hidden;
}
div.code-toolbar>.toolbar .toolbar-item:first-child span:before {
    visibility: visible;
    content: "Example" !important;
}
```

1. Replace the text '**Example**' with your desired text.
2. Click **Save**.

![](https://cdn.document360.io/860f9f88-412e-4570-8222-d5bf2f4b7dd1/Images/Documentation/image-1766998756574.png)
