---
title: "Subfolder hosting"
slug: "subfolder-hosting"
description: "Optimize your SEO with subfolder hosting for your Document360 Knowledge base, enhancing authority and structure under your main domain."
updated: 2026-06-20T07:56:29Z
published: 2026-06-20T07:58:08Z
canonical: "docs.document360.com/subfolder-hosting"
---

> ## 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.

# Subfolder hosting

Subfolder hosting lets you serve your Document360 Knowledge base site from a path under your main domain, such as `example.com/docs`, instead of a separate subdomain like `docs.example.com`. A subfolder (or subdirectory) appears after the root domain in a URL and helps structure content logically under your existing site. Hosting documentation in a subfolder rather than a subdomain is generally better for search engine optimization, since search engines treat subfolder content as part of your main domain's authority. Subfolder hosting can be enabled for both Document360-provided domains and mapped custom domains.

---

## When to use subfolder hosting

Use subfolder hosting when you want your documentation to live under your existing website domain rather than a separate subdomain.

- You want your knowledge base to benefit from your main domain's SEO authority instead of building authority separately on a subdomain.
- Your brand or marketing guidelines require all customer-facing content under a single root domain.
- You want a URL like `example.com/help` instead of `help.example.com`.

---

## Before you begin

:::(Info) (<p class="fa-regular fa-circle-exclamation" data-type="icon"></p> NOTE)
Subfolder hosting is currently supported only for public Knowledge base projects. For private or mixed-access projects, readers are redirected to the Document360 identity login page for authentication, which can't be proxied through a customer's server. As a result, subfolder hosting can't be used for projects that require sign-in.
:::

You'll also need access to your web server's configuration (Nginx, Apache, IIS, or ASP.NET Core) to proxy requests to Document360, since subfolder hosting requires server-side configuration outside of Document360 itself.

---

## How to enable subfolder hosting

1. Navigate to {{variable.Settings}}<span class="fa-regular fa-gear"></span> > {{variable.Knowledge base site}} in the left navigation bar of the {{variable.Knowledge base portal}}.
2. Navigate to {{variable.Custom domain}}.
3. On the **Custom domain** page, navigate to the {{variable.Subfolder hosting}} tab. By default, the **Subfolder path** is set to **/docs**.
4. Turn on the toggle next to **Knowledge base is hosted as a subfolder**.

<img src="https://cdn.document360.io/860f9f88-412e-4570-8222-d5bf2f4b7dd1/Images/Documentation/subfolder hosting.png" class="article_image" alt="Settings for custom domain mapping and subfolder hosting in knowledge base portal.">

When this toggle is on, the public preview of articles becomes visible, and the workspace slug is no longer inserted automatically when you add links in articles.

Subfolder hosting is now enabled for your project.

---

## How to set a custom subfolder path

You can host your knowledge base on a subfolder path other than `/docs`, such as `/help` or `/support`.

1. Navigate to {{variable.Settings}}<span class="fa-regular fa-gear"></span> > {{variable.Knowledge base site}} in the left navigation bar of the {{variable.Knowledge base portal}}.
2. Navigate to {{variable.Custom domain}}.
3. On the **Custom domain** page, navigate to the {{variable.Subfolder hosting}} tab.
4. Clear the **Subfolder path** field and enter your custom path, for example `/help`.
5. Click **{{variable.Update}}**.

<img src="https://cdn.document360.io/860f9f88-412e-4570-8222-d5bf2f4b7dd1/Images/Documentation/subfolder path.png" class="article_image" alt="Custom domain mapping settings for subfolder hosting and API path configuration.">

When setting up a path other than the default, also account for the languages associated with each workspace in your project; server configuration for this varies by web server. Your custom subfolder only takes effect once subfolder hosting is enabled, and your server must be configured to proxy requests for this path — see the platform-specific server articles for guidance.

:::(Info) (<p class="fa-regular fa-circle-exclamation" data-type="icon"></p> NOTE)
For projects configured with a custom domain and subfolder hosting, the **Article preview** option isn't supported yet.
:::

---

## How to set a custom Site API path

By default, the **Site API path** is set to `/api`. You can customize this from the same **Subfolder hosting** tab — for example, to `/docs-api` or `/api-docs`, if `/api` is already used by another application on your domain.

1. Navigate to {{variable.Settings}}<span class="fa-regular fa-gear"></span> > {{variable.Knowledge base site}} in the left navigation bar of the {{variable.Knowledge base portal}}.
2. Navigate to {{variable.Custom domain}}.
3. On the **Custom domain** page, navigate to the {{variable.Subfolder hosting}} tab. By default, the **Site API path** is set to **/api**.
4. Clear the **Site API path** field and enter your custom path, for example `/docs-api`.
5. Click **{{variable.Update}}**.

<img src="https://cdn.document360.io/860f9f88-412e-4570-8222-d5bf2f4b7dd1/Images/Documentation/site API path.png" class="article_image" alt="Custom domain mapping settings for subfolder hosting and API path configuration.">

After setting the Site API path, configure a matching location block on your web server, and ensure the value you enter here exactly matches the path in your server's reverse proxy setup. Refer to the platform-specific server guide for examples:

<div class="doc360-card-row">
  <div class="doc360-card">
    <div class="doc360-card__header">
      <p class="doc360-card__title">Nginx server</p>
    </div>
    <p class="doc360-card__desc">Subfolder hosting configuration for Nginx.</p>
    <a href="/help/docs/nginx-server" target="_blank" class="doc360-card__link">Learn more →</a>
  </div>
  <div class="doc360-card">
    <div class="doc360-card__header">
      <p class="doc360-card__title">ASP.NET Core server</p>
    </div>
    <p class="doc360-card__desc">Subfolder hosting configuration for ASP.NET Core.</p>
    <a href="/help/docs/aspnet-core-server" target="_blank" class="doc360-card__link">Learn more →</a>
  </div>
  <div class="doc360-card">
    <div class="doc360-card__header">
      <p class="doc360-card__title">Microsoft IIS server</p>
    </div>
    <p class="doc360-card__desc">Subfolder hosting configuration for IIS.</p>
    <a href="/help/docs/microsoft-iis-server" target="_blank" class="doc360-card__link">Learn more →</a>
  </div>
  <div class="doc360-card">
    <div class="doc360-card__header">
      <p class="doc360-card__title">Apache HTTP server</p>
    </div>
    <p class="doc360-card__desc">Subfolder hosting configuration for Apache.</p>
    <a href="/help/docs/apache-http-server" target="_blank" class="doc360-card__link">Learn more →</a>
  </div>
</div>

:::(Warning) (Both paths are required)
Subfolder hosting works only when both the **Subfolder path** and the **Site API path** are defined. The Custom Site API path is not the same as the path for API Documentation.
:::

---

## What happens next

Once your web server is configured, your Knowledge base site is live on your custom subfolder. However, the existing Document360 URL continues to serve requests as well — for example, both `example.document360.io` and `example.com/docs` will point to your Knowledge base site. This causes duplicate content in search engines like Google and Bing.

To prevent duplicate content, enable the **Restrict subdomain access** toggle under {{variable.Settings}}<span class="fa-regular fa-gear"></span> > {{variable.Knowledge base site}} > {{variable.Custom domain}} > {{variable.Subfolder hosting}}. Make sure a canonical domain is configured before enabling this toggle — once enabled, your Document360 subdomain automatically redirects to your canonical domain.

---

## Common web servers

| Web server | Notes |
|---|---|
| Apache HTTP server | See the Apache HTTP server article. |
| Nginx server | See the Nginx server article. |
| ASP.NET Core server | See the ASP.NET Core server article. |
| Microsoft IIS server | See the Microsoft IIS server article. |
| OpenResty server | Configuration follows the same proxy principles as Nginx. |
| LiteSpeed server | Configuration follows the same proxy principles as Apache or Nginx. |
| Cloudflare server | Often used alongside another origin server for DNS and proxying. |

:::(Info) (What is a web server?)
A web server stores and delivers website content — text, images, video, and application data — to clients that request it, most commonly a web browser.
:::

---

## Best practices

- Define both the Subfolder path and the Site API path together; subfolder hosting won't function correctly if only one is set.
- Use a path other than `/api` for your Site API path if your domain already serves another application at `/api`, and keep the portal setting and server configuration in sync.
- Enable **Restrict subdomain access** only after your canonical domain is fully configured, to avoid redirect issues.
- Test your subfolder configuration on a staging path before applying it to your production domain.

---

## FAQ

<div class="faq-wrapper" data-type="details-wrapper">
<details open>
<summary><p>What is a canonical URL?</p></summary>
<div data-type="details-content"><p>A canonical URL is the official link that tells search engines which version of a page to index when multiple URLs lead to the same content, such as https://example.com/page and https://example.com/page?utm=123. Setting one as canonical prevents duplicate content issues and ensures the preferred URL ranks properly.</p></div>
</details>
<button class="details-arrow" type="button"></button>
</div>

<div class="faq-wrapper" data-type="details-wrapper">
<details>
<summary><p>How can I configure the canonical URL in Document360?</p></summary>
<div data-type="details-content"><p>Use the Canonical domain setting to globally replace the project subdomain with your specified domain across all articles. Navigate to {{variable.Settings}}<span class="fa-regular fa-gear"></span> > {{variable.Knowledge base site}} > {{variable.Custom domain}} > {{variable.Subfolder hosting}}, locate the Canonical domain option, enter your desired domain, and click Save.</p></div>
</details>
<button class="details-arrow" type="button"></button>
</div>
