Editing the Context Path and Then Clicking on Profile or Space Links Triggers a 404 Error

Platform Notice: Data Center Only - This article only applies to Atlassian products on the Data Center platform.

Note that this KB was created for the Data Center version of the product. Data Center KBs for non-Data-Center-specific features may also work for Server versions of the product, however they have not been tested. Support for Server* products ended on February 15th 2024. If you are running a Server product, you can visit the Atlassian Server end of support announcement to review your migration options.

*Except Fisheye and Crucible

Symptoms

After editing the context path in the Confluence Server Base URL, some links related to spaces and some profile links don't contain the new base url, and when clicked generate a 404 error. Also the icons on the top navigation bar will render letters instead of icons:

(Auto-migrated image: description temporarily unavailable)

 There will be NO errors shown in the atlassian-confluence.log file for this behavior.

Cause

This problem happens because there's a "/" on the context path parameter in the server.xml file, which is not well handled by Tomcat.

Resolution

  1. Stop the Confluence server.

  2. Go to your <Confluence Install Directory>/conf.

  3. Edit the server.xml file.

  4. In the Context element, change the value of the path from:

    1 Context path="/"

    to

    1 Context path=""
  5. Save the file.

  6. Start Confluence.

Updated on April 16, 2025

Still need help?

The Atlassian Community is here for you.