Serving a Hugo Site from Multiple Domains Using Relative URLs

Serving a Hugo Site from Multiple Domains Using Relative URLs Want to host the same Hugo site on multiple domains without generating separate versions? By configuring Hugo to use relative URLs, you can efficiently serve the same fileset across multiple domains. Here’s how you can set it up. Steps to Enable Relative URLs in Hugo 1. Configure Hugo to Use Relative URLs In your config.toml (or config.yaml/config.json), enable relative URLs by setting the relativeURLs option to true: ...

March 15, 2025 · 2 min · Taner