--- title: "Custom CSS" slug: "custom-css" description: "Customize your Document360 knowledge base with custom CSS for precise control over typography, colors, and layout, enhancing your site's visual appeal." tags: ["Custom CSS", "Knowledge base", "Site Customization"] updated: 2026-11-30T07:07:43Z published: 2026-11-30T07:07:43Z canonical: "docs.document360.com/custom-css" --- > ## 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. # Custom CSS Custom CSS in Document360 lets you apply your own CSS code to change the visual appearance of your knowledge base site beyond what the built-in Site customization settings offer. You write CSS rules directly in the portal, and they are applied globally across your entire knowledge base site. This is the right tool when you need precise control over typography, colors, spacing, table styles, image alignment, or any other visual element that cannot be configured through the standard settings. --- ## When to use custom CSS Use custom CSS when the built-in styling options in Site customization do not give you the level of control you need: - **Override default styles** - change the appearance of elements that are not exposed in the Customize site settings, such as callout colors, table borders, or the "back to top" button. - **Apply brand-consistent typography** - set a specific font family, size, or weight across all articles to match your product's design guidelines. - **Fix layout or spacing issues** - adjust margins, padding, or alignment for specific elements that appear differently than intended. - **Apply visual treatments to images** - center-align images in articles, add shadows, or set consistent dimensions for article illustrations. NOTE For common customizations - body font, heading font, table styles, image alignment, callout colors, and hero section background - Document360 provides pre-built CSS snippets you can insert with one click. See [CSS snippets](https://docs.document360.com/docs/en/css-snippets) before writing custom CSS from scratch. Custom CSS applies only to your live knowledge base site. It is not carried into exported project content, such as the ZIP (JSON/Markdown/HTML) export or the offline WebHelp (HTML) export. If you need styled output outside the live site, you will need to reapply the relevant CSS manually in the exported files. See [Export project as a ZIP file - JSON](/help/docs/exporting-your-document360-project-as-a-zip-file-json) for details. --- ## Before you begin - You must have a user account with admin-level access to the Knowledge base portal. - Custom CSS applies globally to the entire knowledge base site - changes affect all pages and all readers. - Document360 does not validate or lint your CSS code, so errors will not be flagged automatically. - Malformed or conflicting CSS can break the site's layout. Test your changes carefully before saving. --- ## How to add custom CSS 1. Navigate to **Settings** () > **Knowledge base site** in the left navigation bar of the Knowledge base portal. 2. In the left navigation pane, navigate to **Site customization**. 3. Click **Custom CSS & JavaScript**. 4. Select the **CSS** tab. The CSS code editor appears. 5. Enter your CSS code in the text area. ![Site customization page with the Custom CSS & JavaScript option highlighted](https://cdn.document360.io/860f9f88-412e-4570-8222-d5bf2f4b7dd1/Images/Documentation/site-customize-custom-css.png) 1. Press **Ctrl + S** or click **Save** to apply your changes. The CSS is now applied to your knowledge base site. Visit the site to preview the changes. --- ## How to use CSS snippets CSS snippets are pre-written blocks of code you can insert directly into the CSS editor. They cover the most common customization tasks and are designed to be modified for your specific requirements. 1. Navigate to **Settings** () > **Knowledge base site** > **Site customization** > **Custom CSS & JavaScript**. 2. Select the **CSS** tab. 3. Click **Add code snippets** in the top right of the code editor. 4. In the snippets panel, click the desired snippet. The code is inserted into the CSS editor. ![Custom CSS editor with the Find bar at the top and the Add code snippets panel open, showing the seven pre-loaded CSS snippet options](https://cdn.document360.io/860f9f88-412e-4570-8222-d5bf2f4b7dd1/Images/Documentation/code-snippets-css.png) 5. Modify the inserted code as needed - for example, replace the font name, color code, or size value. 6. Press **Ctrl + S** or click **Save**. For detailed walkthroughs of each snippet, see [CSS snippets](https://docs.document360.com/docs/en/css-snippets). --- ## How to find and replace in the CSS editor Use the Find bar at the top of the CSS editor to find selectors, properties, values, or any other text in your custom CSS, and replace it. This is useful when you need to update a value that appears in many rules, such as a brand color or a font name. ### Find text 1. Navigate to **Settings** () > **Knowledge base site** > **Site customization** > **Custom CSS & JavaScript**. 2. Select the **CSS** tab. 3. Click the **Find** field, or click inside the code editor and press **Ctrl + F** (**Cmd + F** on Mac). 4. Enter the text you want to find. All matches are highlighted in the editor, and the match count appears next to the field (for example, **1 of 4**). 5. Press **Enter** or click the **Next match** () icon to go to the next match. Press **Shift + Enter** or click the **Previous match** () icon to go to the previous match. 6. (Optional) Refine the search: - Click **Match case** (`Aa`) to find only matches with the same capitalization. By default, the search ignores case. - Click **Use regular expression** (`.*`) to search with a regular expression pattern. If no text matches, **No results** appears next to the field. ![CSS editor with a search term in the Find field, matches highlighted in the code, the match count, and the Match case and Use regular expression options](https://cdn.document360.io/860f9f88-412e-4570-8222-d5bf2f4b7dd1/Images/Documentation/find-in-css.png) ### Replace text 1. Find the text you want to replace, as described above. 2. Enter the new text in the **Replace** field. 3. Choose how to replace: - Click **Replace** or press **Enter** in the **Replace** field to replace the current match and move to the next one. - Click **Replace all** to replace every match at once. 4. Press **Ctrl + S** or click **Save** to apply your changes. ![CSS editor Find bar with text in the Find and Replace fields and the Replace and Replace all buttons](https://cdn.document360.io/860f9f88-412e-4570-8222-d5bf2f4b7dd1/Images/Documentation/css-replace-replace-all.png) NOTE Replacements are not applied to your knowledge base site until you click **Save**. To undo a replacement, click inside the code editor and press **Ctrl + Z** (**Cmd + Z** on Mac). A single undo reverses an entire **Replace all**. To discard all unsaved changes, click **Cancel**. Find and replace is also available in the JavaScript tab and in the other code editors in Site customization, such as the custom footer, the home page Custom code section, and the Custom style option of error pages. --- ## How to hide the copy link icon next to headings On the published knowledge base site, a Copy link icon appears next to every H2, H3, and H4 heading when readers hover over it. If you prefer not to display this icon — for example, to avoid extra spacing below headings in certain layouts, you can hide it using Custom CSS. ### When to hide the copy link icon Some knowledge base layouts, particularly those with long or wrapped heading text, may show extra space below a heading where the copy link icon sits on its own line. If this affects your site's appearance, you can hide the icon entirely using the CSS snippet below. ### How to hide the icon 1. Navigate to Settings > Knowledge base site in the left navigation bar of the Knowledge base portal. 2. In the left navigation pane, navigate to Site customization. 3. Click Custom CSS & JavaScript. 4. Select the CSS tab. 5. Paste the following snippet into the CSS editor: ``` .copy-link-btn { display: none !important; } ``` 1. Press Ctrl + S or click Save to apply your changes. The copy link icon will no longer appear next to headings on your knowledge base site. NOTE Hiding the copy link icon removes the ability for readers and support teams to copy direct links to specific headings from the knowledge base site. Consider this trade-off before applying the change. --- ## Best practices - **Use the pre-built snippets as a starting point** - even if you need to customise heavily, starting from a snippet ensures the correct selectors and structure for Document360's HTML. - **Use specific selectors** - avoid broad selectors like `body` or `*` unless intentional. Specific selectors reduce the risk of unintentionally overriding other styles. - **Comment your code** - add comments to explain what each block does, especially if multiple team members manage the CSS. Example: `/* Centers all article images — added June 2026 */` - **Test in both light and dark mode** - styles that look correct in light mode may have contrast or visibility issues in dark mode. Always preview both before saving. - **Keep a backup** - before making significant changes, copy the current CSS to a text file. Document360 does not maintain a version history of custom CSS changes. - **Review matches before you click Replace all** - step through the matches with **Enter** and check the match count first. Turn on **Match case** when the same word appears with different capitalization, for example, in class names. If a replacement goes wrong, press **Ctrl + Z** before you save. - Coordinate with your team before editing - custom CSS is a single shared configuration. Document360 does not lock the editor when another user is working, and the most recent save always replaces the previous one. If two team members save changes at the same time or in close succession, one person’s work will overwrite the other’s with no warning. To investigate unexpected changes, go to Team auditing under Settings > Knowledge base portal and filter the Knowledge base site settings events by Custom CSS updated to see who made changes and when. - If your knowledge base is public, it is cached. After saving CSS changes, they may take up to 30 minutes to appear for visitors. To preview changes immediately after saving, clear your browser’s application cache or open the knowledge base in an incognito window. --- ## FAQ **Can I apply custom .css files in Document360?** Yes. Document360 lets you reference and apply custom `.css` files to tailor the appearance and style of your documentation. **If I manage multiple brands, do I need a separate workspace for each?** You can manage multiple brands either by creating separate workspaces within a single project, or by purchasing additional projects for each brand. CSS configured at the project level applies universally across all workspaces. You can still customise the styling of landing pages and other elements for each workspace individually. **Why doesn't custom CSS appear in the shareable preview link?** Custom CSS, JavaScript, and HTML integrations are not applied in the shareable preview link. This is expected behavior — these customizations are intentionally disabled in shareable previews to ensure consistent performance and security when content is shared externally. To view the final appearance of your CSS changes, publish the article and access it directly from the knowledge base site, or use a sandbox environment. **Can I undo a Replace all in the CSS editor?** Yes. Before you save, click inside the code editor and press **Ctrl + Z** (**Cmd + Z** on Mac). A single undo reverses the entire **Replace all**. If you have already saved, the replacement is applied to your knowledge base site, and you need to change the code back manually. **Is find and replace available in the Knowledge base widget and AI chatbot code editors?** No. Find and replace is available only in the code editors in **Site customization**. It is not available in the Custom CSS & JavaScript tab of the Knowledge base widget or the AI chatbot, or in Custom HTML integrations. ## Related - [Custom JavaScript](/custom-javascript.md) - [How to configure a custom font in the knowledge base](/how-to-configure-a-custom-font-in-the-knowledge-base.md) - [CSS Snippets](/css-snippets.md)