logo

How to remove the trailing slash of a URL on a Hugo static website running on Netlify

/ Static Site Generators

I recently migrated www.oprea.rocks from Gatsby.js to Hugo. My biggest complaint was not being able to remove the trailing slash on all pages. Assuming your website is on Netlify, here are the steps to remove trailing slashes on your Hugo website/blog. Enable asset optimization on Netlify You can hand-pick your settings but for this purpose I left them all on — especially the “Pretty URLs” setting. That turns the HTML files generated by Hugo into nicely formatted URLs, but without that ugly, trailing slash.

Read more →

What are STATIC SITE GENERATORS and why YOUR BUSINESS NEEDS to use one

If you’re looking to revamp your website and you’re serious about this, you probably found mentions of static site generators, static sites and the JAMStack, on the Internet. Unfortunately, for every article that tries to explain what are the benefits of using a static site generators, there are other 10 explaining why static sites are not good. In theory: HTML, data and CSS are served from the same place So Adrian, what’s a static site and why do I need one?

Read more →
Copyright (c) 2023 Adrian Oprea. All rights reserved.