404 page
Custom not-found page — enable via publier.config.yaml, add with src/pages/404.astro.
The 404 standard page provides a custom not-found handler. Enable it in publier.config.yaml, then add src/pages/404.astro to match your site’s design.
Enable / disable
pages: 404: true # false to suppress the custom 404 handlerAdding a custom 404
Create src/pages/404.astro:
---import BaseLayout from '@publier/shell/layouts/base-layout.astro';---
<BaseLayout title="404 — Page not found"> <main class="max-w-xl mx-auto my-32 px-6 text-center"> <h1 class="text-6xl font-bold">404</h1> <p class="mt-4">The page you were looking for doesn't exist.</p> <a href="/" class="btn btn-primary mt-6">Go home</a> </main></BaseLayout>BaseLayout injects the site nav, footer, theme CSS, and head boilerplate.