List of built-in settings. (You can create your own settings.)

Basic

  • Page: The page's root component.
  • Layout: The page's layout component.
  • Wrapper: Component(s) that wrap the page's root component.
  • route: string | Function The page's route.
  • prerender: Whether to pre-render the page, and pre-rendering settings.
  • client: string Add client code.
  • redirects: Permanent redirections (HTTP status code 301).
  • keepScrollPosition: Whether the page scrolls to the top upon navigation.
  • prefetchStaticAssets: Link prefetching settings.
  • baseAssets: Base URL of server.
  • baseServer: Base URL of static assets.
  • host: Make development/preview server available over LAN and public addresses.
  • port: Change port of development/preview server.
  • mode: Set the mode to run in.
  • extends: Install Overview > Extensions.
  • react: vike-react Options passed to React functions such as createRoot() or hydrateRoot().

HTML

  • Head: Add arbitrary <head> tags.
  • title: Set the page's title.
  • description: Set the page's description.
  • image: Set the page's preview image upon URL sharing.
  • viewport: Set the page's viewport size on mobile devices.
  • lang: Set the page's language (<html lang>).
  • htmlAttributes: Add tag attributes such as <html class="dark">.
  • bodyAttributes: Add tag attributes such as <body class="dark">.
  • bodyHtmlBegin: Insert HTML at the beginning of <body>.
  • bodyHtmlEnd: Insert HTML at the end of <body>.

You create your own custom HTML settings, see Guides > <head> tags > Custom settings.

Advanced

Most users don't need to know about these settings.

See also