Skip to content
C Cyberline Solutions

Independent Footer Menu — Different Links in Header and Footer

Astro Rocket now lets you configure the footer menu independently of the header navigation. Add a Privacy link, an Imprint, or a Cookie Policy without cluttering your main nav.

H

Hans Martens

3 min read

Until now, the footer in Astro Rocket reused the same links as the header. That’s fine for a small site, but most blogs want the footer to do something different — show legal pages like Privacy and Terms, or surface less prominent links that don’t deserve a spot in the main nav.

The footer menu is now configured independently from the header. You can keep the header focused on your primary navigation while the footer holds everything else.

What changed

There are now three exports in src/config/nav.config.ts:

  • navItems — the header menu (unchanged)
  • footerNavItems — the footer menu, configured separately
  • legalLinks — small legal-style links rendered in the footer’s bottom row

By default, footerNavItems mirrors navItems so existing sites look identical. You only need to edit it when you want the footer to differ.

Open src/config/nav.config.ts and edit the footerNavItems array:

export const footerNavItems: NavItem[] = [
  { label: 'Blog', href: '/blog', order: 1 },
  { label: 'Projects', href: '/projects', order: 2 },
  { label: 'About', href: '/about', order: 3 },
  { label: 'Contact', href: '/contact', order: 4 },
  { label: 'Privacy', href: '/privacy', order: 5 },
];

The header stays untouched. The footer now has the extra link.

For Privacy/Terms/Imprint-style links, the footer has a separate “legal” row that some layouts (columns, stacked) render in a dedicated bottom strip. Add them to legalLinks:

export const legalLinks: LegalLink[] = [
  { label: 'Privacy', href: '/privacy' },
  { label: 'Terms', href: '/terms' },
  { label: 'Imprint', href: '/imprint' },
];

These render as small, muted links in the footer’s bottom-right corner. They don’t appear in the header.

Two ways to override per page

If you want a specific page to use a different footer menu (rare, but possible), the <Footer /> component still accepts a nav prop and a legalLinks prop. They override the config:

<Footer
  nav={[{ label: 'Home', href: '/' }]}
  legalLinks={[{ label: 'Privacy', href: '/privacy' }]}
/>

When you don’t pass them, the config takes over.

NavItem now has an optional external?: boolean field. Set it to true (or use a https:// URL) and the link opens in a new tab with rel="noopener noreferrer":

{ label: 'GitHub', href: 'https://github.com/you', order: 5, external: true }

Where it shows up

The new behaviour is wired into all four footer layouts — simple, columns, minimal, and stacked. Existing sites get the same links they had before; new sites only edit one file when they want the footer to differ from the header.

That’s it. One file, one extra array, full control over the bottom of the page.

Share:

Related Posts

Table of Contents — Reading Anchors for Long Posts

Astro Rocket renders an optional TOC on blog posts in three layouts — inline card, sticky sidebar, or both — with the sidebar on the left or right. Pick what fits your audience.

H Hans Martens
2 min read
#astro-rocket #features #blog #navigation

Video Slides in Project Galleries — Zero Bytes Until Play

Project carousels now accept self-hosted video slides next to images. Here's how to use them, how they work, and why they don't cost a single Lighthouse point.

H Hans Martens
2 min read
#astro-rocket #features #projects #performance

Comments on Blog Posts — Giscus or Cusdis, Lazy-Loaded

Astro Rocket's blog comments are now pluggable: pick Giscus (GitHub Discussions) or the self-hostable, privacy-friendly Cusdis. Both lazy-load on scroll — skip them and you pay nothing.

H Hans Martens
2 min read
#astro-rocket #features #blog #comments #giscus #cusdis

Follow along

Stay in the loop — new articles, thoughts, and updates.