hugo.Version
Returns the current version of the Hugo binary.
- Syntax
- hugo.Version
- Returns
- hugo.VersionString
Usage
The hugo.Version function returns the current version of the Hugo binary. Use comparison functions such as compare.Ge and compare.Lt with the returned value to compare versions by semantic version precedence instead of by string order.
Examples
{{ hugo.Version }} → 0.169.0Comparing versions:
{{ ge hugo.Version "0.99.0" }} → true
{{ lt hugo.Version "0.200.0" }} → trueLast updated:
November 8, 2026
:
content: Apply style guide to hugo functions (ed4f37ecc)
Improve this page