Go Static Site Generator vs Hugo: I Just Built One, Here's the Honest Comparison
This site runs on a static site generator I wrote in Go, in this very project. That puts me in an unusual position: I have now built a generator and used Hugo-style generators, so this comparison is not theoretical.
Why I built my own instead of using Hugo
Hugo is excellent and you should probably use it. I did not, for three concrete reasons:
- The calculators are data, not content. Nine calculators on this site share one tested math engine (
internal/calc). I wanted the generator to read the same Go definitions and render pages from them — not to duplicate the logic in a template language. - I needed tight coupling with Go. The whole point of the site is transparent, verified math. Being able to run the same functions at build time (server-side defaults) and in the browser (mirrored JS) is a real advantage, and it is awkward to bolt onto a third-party generator.
- I enjoy maintaining the 600 lines it took. That is an honest tradeoff: for me the maintenance is a feature. For most people it is a cost.
When Hugo wins
- Content velocity: Hugo turns Markdown into a site with themes, taxonomies, shortcodes, and i18n out of the box. My generator needed a few days of work to reach a fraction of that.
- Ecosystem: themes, documentation, and a community mean problems are solved before you have them.
- You do not want to maintain a generator. That is most people, and it is not a character flaw.
When rolling your own wins
- Data-driven pages that must match application logic exactly (calculators, pricing tables, comparisons generated from CSV/YAML).
- Domain-specific output — custom sitemaps, JSON-LD, structured data, or integration with code that already exists in your stack.
- You are a Go developer and the generator is a few hundred lines you fully understand.
The honest verdict
If I were building a content-heavy blog with no data-driven component, I would use Hugo and never look back. This site is different: the calculators are the product, and they need to come from the same code that tests them. So I built the generator.
The decision is not "which is better" — it is "where does your content come from." If it comes from Markdown, use Hugo. If it comes from data and code, write the generator. Know which one you are building, and the choice makes itself.
Comments (0)
No comments yet.