encoding.Base64Encode
Returns the base64 encoding of the given content.
- Syntax
- encoding.Base64Encode INPUT
- Returns
- string
- Alias
- base64Encode
Usage
The encoding.Base64Encode function returns the base64 encoding of the given content. The function converts the input to a string before encoding it. Use the encoding.Base64Decode function to reverse the operation.
Examples
{{ "Hugo" | encoding.Base64Encode }} → SHVnbw==
{{ 42 | encoding.Base64Encode }} → NDI=Last updated:
November 8, 2026
:
content: Remove categories from front matter (1cc1dd83a)
Improve this page