How to Customize Navigation Menus in the Koha OPAC

Complete guide to customizing Koha OPAC navigation using OpacNav, OpacNavBottom, opacheader, and OpacMoreSearches. Includes examples, multi-branch tips, and limitations.

Koha OPAC navigation is controlled by four system preferences: OpacNav (left sidebar links), OpacNavBottom (below the left sidebar), opacheader (top strip across every page), and OpacMoreSearches (additional links below the search bar). Each preference accepts raw HTML and injects it into a specific rendered location. You edit them in Administration > Koha System Preferences > OPAC.

This gives you meaningful control — you can add links to custom pages, remove Koha’s default suggestions, and restructure the left nav entirely. The ceiling is that all editing happens in an HTML textarea with no visual preview, and at scale (many branches, many links), managing nav consistency becomes genuinely difficult.

The Four Navigation Preferences: Full Breakdown

OpacNav

Where it renders: Left sidebar column, visible on the OPAC homepage and most OPAC pages (search results, item details, patron account).

What it accepts: Any valid HTML. In practice, it’s almost always a <ul> or <nav> containing <li><a> elements.

Default behavior: In a fresh Koha install, OpacNav is empty or contains a few placeholder links. Whatever you put here replaces the default content entirely.

Example — a clean custom left nav:

<nav aria-label="Library navigation">
  <ul>
    <li><a href="/cgi-bin/koha/opac-page.pl?page=3">Library Hours</a></li>
    <li><a href="/cgi-bin/koha/opac-page.pl?page=4">Borrowing Policy</a></li>
    <li><a href="/cgi-bin/koha/opac-page.pl?page=5">Digital Resources</a></li>
    <li><a href="/cgi-bin/koha/opac-user.pl">My Account</a></li>
    <li><a href="/cgi-bin/koha/opac-page.pl?page=6">Contact Us</a></li>
  </ul>
</nav>

OpacNavBottom

Where it renders: Directly below the OpacNav block in the left sidebar.

What it accepts: HTML.

Common uses: Secondary navigation (social media links, accessibility statement), legal links (privacy policy, terms), or a small “powered by” credit. Keeps primary and secondary nav visually separated without editing one large HTML block.

opacheader

Where it renders: The very top of every OPAC page — above the search bar and above OpacNav. It is sitewide, not just the homepage.

What it accepts: HTML, including inline styles or a <style> block.

Common uses:

  • A library logo lockup (if your Koha version’s default header doesn’t support your branding)
  • A sitewide announcement banner (“System maintenance Saturday 10pm–midnight”)
  • A top navigation bar with links that appear on every page
  • An emergency closure notice

Example — announcement banner:

<div style="background:#b5451b;color:#fff;text-align:center;padding:6px 12px;font-size:0.9rem;">
  All branches closed Monday 20 January for staff development day.
</div>

OpacMoreSearches

Where it renders: Below the main search bar on the OPAC homepage, as additional link options.

What it accepts: HTML — typically <a> tags.

Common uses: Links to external search tools (“Search WorldCat”, “Search OverDrive”), links to specialized Koha search URLs (authority search, course reserves), or a “Search our A–Z databases” link.

Example:

<a href="https://worldcat.org/search?q={searchTerms}" target="_blank" rel="noopener">Search WorldCat</a>
&bull;
<a href="/cgi-bin/koha/opac-search.pl?idx=ti&amp;q=">Advanced Search</a>

Practical Walkthrough: Restructuring the Left Nav

Scenario: Your library wants to replace Koha’s default OpacNav with links to a policies page, an hours page, and a contact page — and remove any Koha-generated links that don’t fit the library’s brand.

  1. Go to Administration > Koha System Preferences > OPAC.
  2. Find OpacNav.
  3. Clear the existing content.
  4. Paste your custom link list (see OpacNav example above).
  5. Find OpacNavBottom.
  6. Add secondary links:
    <ul>
      <li><a href="/cgi-bin/koha/opac-page.pl?page=9">Privacy Policy</a></li>
      <li><a href="https://twitter.com/yourlibrary" rel="noopener" target="_blank">Follow us on Twitter</a></li>
    </ul>
    
  7. Click Save all OPAC Preferences.
  8. Switch to your OPAC and hard-refresh to verify.

Multi-Branch Navigation

Koha allows per-branch overrides of OpacNav. When the OPACBranches system preference is enabled and a patron selects their home branch, Koha can serve branch-specific versions of OpacNav.

To set branch-specific OpacNav values:

  • Go to Administration > Libraries.
  • Edit the branch record.
  • Look for the OpacNav field in the branch settings (available in Koha 22.11+).
  • Enter HTML specific to that branch.

If a branch has no custom OpacNav set, it falls back to the global OpacNav preference.

This is useful when different branches have different hours pages, different event schedules, or different supplementary collections to highlight.

Limitations of Native Navigation Customization

  • HTML in a textarea. Every change is written by hand. A missing </li> or </ul> breaks the nav silently — you won’t see an error, just a broken layout.
  • No visual editor. You paste HTML, save, and then reload the OPAC to see the result. Rapid iteration requires many browser tab switches.
  • Immediate live changes. There is no draft mode. Saving a broken nav affects every patron on the site right away.
  • No link management at scale. If you have 20 links across OpacNav, OpacNavBottom, and opacheader, keeping them consistent (same formatting, updated URLs after a page is deleted) is a manual process.
  • Branch nav is database-level only. Per-branch OpacNav overrides require going into each branch record individually. There’s no UI that shows you all branches’ nav values side by side.
  • CSS inconsistency. Your nav HTML inherits Koha’s default stylesheet. Making nav links look like a modern styled component requires OPACUserCSS overrides that grow in complexity with every iteration. See OPACUserCSS and OPACUserJS Guide.

When Theme Builder Is the Better Option

If you want:

  • A top navigation bar that matches your library’s branding (not Koha’s default header)
  • Mega-menus, dropdowns, or mobile-responsive hamburger menus
  • Nav that is consistent across homepage, search results, and custom pages
  • Branch-specific nav managed from a single interface rather than individual branch records
  • Staff who can update nav links without writing HTML

…the native preference approach will require ongoing developer attention. KohaSupport Theme Builder includes a structured navigation builder as part of its theme system. Nav links are managed in a configuration layer, tested against both desktop and mobile viewports, and applied consistently across every OPAC page through the theme’s template layer.

See How to Customize the Koha OPAC Homepage for how nav customization fits into the broader homepage picture. If you want a structured non-HTML workflow, start with the Theme Builder Documentation Hub and How to Configure Navigation in Theme Builder.

Frequently Asked Questions

Can I add dropdown menus to Koha OPAC navigation? Yes, but not through a preference alone. You’d write the dropdown HTML in OpacNav and add the corresponding CSS in OPACUserCSS, plus JavaScript in OPACUserJS for keyboard/mobile accessibility. It’s achievable but requires front-end development skills and must be re-tested after every Koha upgrade.

Can I remove the default Koha navigation links entirely? Yes. Setting OpacNav to your own HTML replaces whatever Koha would otherwise render in that zone. However, some nav elements (like the “Log in” link) are rendered by the Koha template itself and are not controlled by OpacNav — you would need OPACUserCSS to hide those or a custom theme to relocate them.

How do I link my custom pages in the navigation? Use the URL format /cgi-bin/koha/opac-page.pl?page=N where N is the page ID assigned by the Pages tool. See How to Create Custom Pages in Koha for the full workflow.

Do navigation changes affect the staff interface? No. OpacNav, OpacNavBottom, opacheader, and OpacMoreSearches only affect the patron-facing OPAC. The staff interface has a separate set of customization preferences.


For the complete overview of every Koha customization option, see the Koha Customization Guide.

Related: How to Create Custom Pages in Koha · OPACUserCSS and OPACUserJS Guide · Theme Builder Documentation Hub · How to Configure Navigation in Theme Builder


Nav links in a textarea are a starting point, not a solution.
Theme Builder gives you a structured navigation system — responsive menus, consistent branding, and branch-specific control — managed without writing a line of HTML.

Explore Koha Theme Builder™   Book a consultation

Next Steps

More in Koha System

Was this article helpful?

Thanks for your feedback!