Search code examples
python-sphinxread-the-docs

Disabling the top navigation bar (breadcrumbs) in Sphinx ReadTheDocs theme


I would like to disable the top navigation bar of the ReadTheDocs theme. For other theme, for instance classic it is just an option

html_theme = "classic"
html_theme_options = {
    "showrelbartop": False
}

How I can modify the read the docs theme to disable this top navigation bar?

Edit: After processing the source files with make html, I have to remove these lines in html files

<div role="navigation" aria-label="breadcrumbs navigation">
  <ul class="wy-breadcrumbs">
    <li><a href="index.html">Docs</a> &raquo;</li>
    <li></li>
      <li class="wy-breadcrumbs-aside">
      </li>
  </ul>
  <hr/>
</div>

to obtain the expected result. Is it possible to obtain this result before compiling the sources with make html?


Solution

  • I assume you refer to the breadcrumbs (breadcrumbs.html). You can simply open the main template file - layout.html - and delete or comment out the following line:

    {% include "breadcrumbs.html" %}