Header pinning
Overview
Website pages keep their header — the navbar and, on narrow screens, the sidebar toggle bar — fixed to the top of the viewport. To leave more room for reading, the header slides out of view as you scroll down and reappears as soon as you scroll back up.
This matches Quarto 1’s behavior and needs no configuration.
Keeping the header always visible
To keep the navbar on screen at all times, pin it:
website:
title: "My Site"
navbar:
pinned: true
left:
- href: index.qmd
text: HomeWith pinned: true the header stays fixed at the top and never slides
away.
Sidebars accept the same option; pinning either the navbar or the sidebar keeps the whole header in place:
website:
sidebar:
pinned: true
contents:
- index.qmd