alias
On this page
Alias
Generate redirect pages for old URLs when migrating a site.
hooks: alias: enabled: true option: - "/old-url/:/new-url/" - "/old-post.html:/posts/new-post/"
Each entry uses old-path:new-path. The old path must be a site-local path because it is written to the output directory. Query strings, fragments, and backslashes are not allowed. The destination may be a site-local path or a full external URL.
Old paths ending in / produce an index.html file. Paths without an extension are also treated as directories.