Doc

List of Params in hugo.toml config file

List of Params in hugo.toml config file Sugam Pokharel

This page lists all parameters currently present in the theme hugo.toml and what they do. Some major parameters and their workings have already been described in more detail here

Root-level params

ParameterDescriptionExample
baseURLBase URL used when generating absolute links.`https://example.org/`
languageCodeDefault language code for the site.`en-US`
titleGlobal site title shown in headers and metadata.`My New Hugo Site`
readingSpeedWords-per-minute value used to calculate `.ReadingTime`.`212`
Table: Root-level Hugo parameters

Taxonomies ([taxonomies])

ParameterDescriptionExample
tagSingular key mapped to plural taxonomy URL for tags.`tag = "tags"`
categorySingular key mapped to plural taxonomy URL for categories.`category = "categories"`
authorSingular key mapped to plural taxonomy URL for authors.`author = "authors"`
Table: Taxonomy mapping

The [[menus.main]] block is repeated for each menu item.

Module version params ([module.hugoVersion])

ParameterDescriptionExample
extendedWhether extended Hugo build is required by module metadata.`false`
minMinimum Hugo version required by this theme.`0.146.0`
Table: Hugo version constraints

Goldmark renderer params ([markup.goldmark.renderer])

ParameterDescriptionExample
unsafeAllows raw HTML rendering inside Markdown content.`true`
Table: Goldmark renderer

The [[related.indices]] block is repeated for each index rule.

General params ([params])

ParameterDescriptionExample
paginationSizeNumber of items shown per paginated list page.`6`
summaryLengthMaximum summary length used in cards and lists.`180`
Table: General theme params

Feature toggles ([params.features])

ParameterDescriptionExample
enableSearchShows or hides site search UI and behavior.`false`
enableBackToTopShows or hides back-to-top button on pages.`true`
enablePaginationEnables pagination on list pages.`true`
enableThemeToggleShows or hides light/dark toggle button.`true`
enableMathAllows MathJax on pages that request math rendering.`true`
enableBreadcrumbsShows or hides breadcrumb trail.`true`
enableRelatedPostsShows or hides related posts section.`true`
fixedThemeWhenToggleOffTheme forced when toggle is disabled (`light` or `dark`).`light`
Table: Feature flags

UI params: Header and Theme ([params.ui])

ParameterDescriptionExample
titleSeparatorSeparator used in `<title>` between page title and site title.``
skipLinkTextAccessible skip-link text for keyboard users.`Skip to main content`
primaryNavAriaLabelARIA label for primary navigation.`Primary`
brandKickerSmall kicker text above main site title.`Literary Journal`
navToggleTextText label for mobile menu toggle.`Menu`
navToggleAriaLabelARIA label for navigation toggle button.`Toggle navigation`
themeStorageKeyLocalStorage key used to persist selected theme.`mytheme-color-scheme`
themeDefaultDefault theme when no user preference exists.`light`
themeToggleLabelDarkModeToggle text when action is switching to dark mode.`Dark`
themeToggleLabelLightModeToggle text when action is switching to light mode.`Light`
themeToggleAriaToDarkARIA label when toggle will switch to dark.`Switch to dark mode`
themeToggleAriaToLightARIA label when toggle will switch to light.`Switch to light mode`
Table: Header and theme UI labels

UI params: Search ([params.ui])

ParameterDescriptionExample
searchToggleTextText label on header search button.`Search`
searchToggleAriaLabelARIA label for opening search dialog.`Open search`
searchDialogTitleHeading and ARIA label used in search dialog.`Search`
searchCloseLabelText and ARIA label for closing search dialog.`Close search`
searchPlaceholderPlaceholder text inside search input.`Search posts`
searchNoResultsTextText shown when zero results are found.`No results found`
searchEmptyPromptHint text shown before typing search terms.`Search by title, subtitle...`
searchLoadFailedTextFallback message if Pagefind assets/index are missing.`Search index is not available...`
searchLoadingTextTemporary text while search UI initializes.`Loading search...`
searchResultLabelSingular label used in result count.`result`
searchResultsLabelPlural label used in result count.`results`
Table: Search UI labels

UI params: Fonts, Home, Lists, Pagination, TOC ([params.ui])

ParameterDescriptionExample
fontPreconnectPrimaryFirst preconnect URL for web font performance.`https://fonts.googleapis.com`
fontPreconnectSecondarySecond preconnect URL for font asset host.`https://fonts.gstatic.com`
fontStylesheetHrefFont stylesheet URL loaded by theme.`https://fonts.googleapis.com/css2?...`
mathJaxScriptMathJax script URL used for math-enabled pages.`https://cdn.jsdelivr.net/...`
homeEditorHeadingHeading for editor intro block on home page.`From the Editor`
homeFeaturedEyebrowEyebrow label above featured post block.`Featured Story`
homeFeaturedCtaCTA text for featured post button/link.`Read featured story`
homeLatestEyebrowEyebrow label above latest posts area.`Latest Writing`
homeLatestHeadingHeading for latest posts section.`Recent Articles`
sectionEyebrowEyebrow label for section list pages.`Collection`
taxonomyEyebrowEyebrow label for taxonomy list pages.`Browse`
articleCardCtaCTA label used in article cards.`Read more...`
paginationAriaLabelARIA label for pagination navigation.`Pagination`
paginationPrevLabelText label for previous-page pagination link.`Previous`
paginationNextLabelText label for next-page pagination link.`Next`
tocHeadingTable of contents section heading text.`Table of Contents`
tocStartLevelMinimum heading level included in TOC.`2`
tocEndLevelMaximum heading level included in TOC.`4`
tocOrderedWhether TOC should render as ordered list.`false`
Table: Layout, typography, and content UI labels

UI params: Article, Footer, and Shortcodes ([params.ui])

ParameterDescriptionExample
articleFallbackTypeFallback label when content type is unavailable.`Article`
articleByLabelLabel before article author names.`By`
articlePublishedLabelLabel before publish date.`Published`
articleUpdatedLabelLabel before updated date.`Updated`
articleReadingTimeLabelLabel before reading-time value.`Reading time`
articleMinReadLabelUnit label for reading time.`min read`
articlePostNavAriaLabelARIA label for previous/next post navigation.`Post navigation`
articlePrevLabelLabel for previous post link.`Previous`
articleNextLabelLabel for next post link.`Next`
articleShareHeadingHeading text for share section.`Share this article`
articleShareAriaLabelARIA label for share section.`Share this article`
articleCommentsHeadingHeading text for comments section.`Comments`
articleCommentsAriaLabelARIA label for comments section.`Comments`
articleCommentsEnableJsLabelNoscript message for comments providers needing JS.`Please enable JavaScript...`
footerTaglineFooter tagline text.`Essays, criticism...`
footerCopyrightFooter copyright template text (`{year}` is replaced).`Copyright {year}...`
shortcodeCollapseTitleDefault title for collapse shortcode.`Click to expand`
shortcodeCardsDefaultTitleDefault card title for cards shortcode.`Card`
shortcodeTabsDefaultTitleDefault title for tabs shortcode.`Tab`
shortcodeAccordionDefaultTitleDefault section title for accordion shortcode.`Section`
shortcodeTableCaptionPrefixPrefix text used in table shortcode captions.`Table:`
shortcodeSocialLinksHeadingHeading used by social-links shortcode.`Social Media Links`
shortcodeSlideshowPrevLabelLabel for previous-slide button.`Previous slide`
shortcodeSlideshowNextLabelLabel for next-slide button.`Next slide`
shortcodeCodeCopyLabelButton label before code is copied.`Copy`
shortcodeCodeCopiedLabelButton label after successful code copy.`Copied`
shortcodeCodeFailedLabelButton label when code copy fails.`Failed`
Table: Article, footer, and shortcode UI labels

Taxonomy label params ([params.ui.taxonomyLabels])

ParameterDescriptionExample
categoriesLabel text used for categories taxonomy.`Categories`
tagsLabel text used for tags taxonomy.`Tags`
authorsLabel text used for authors taxonomy.`Authors`
Table: Displayed taxonomy names

Archive behavior params ([params.archive])

ParameterDescriptionExample
sectionsSections included in archive listing.`["posts"]`
groupByDate format token used for archive grouping.`2006`
showYearCountShow or hide yearly post counts.`true`
Table: Archive settings

Related-post display params ([params.related])

ParameterDescriptionExample
countMaximum related posts displayed per article.`3`
sameSectionOnlyRestrict related posts to same section when true.`true`
summaryLengthMaximum summary length in related cards.`145`
showSummaryShow or hide summary text in related cards.`true`
Table: Related-post display settings

Share params ([params.share])

ParameterDescriptionExample
networksOrdered list of social networks shown in share bar.`["x", "facebook", ...]`
Table: Share network settings

Comment provider params ([params.comments])

ParameterDescriptionExample
enabledGlobally enable or disable comments rendering.`false`
providerActive provider key (`giscus` or `disqus`).`giscus`
Table: Comment system toggle

Giscus params ([params.comments.giscus])

ParameterDescriptionExample
repoGitHub repository in `owner/repo` format.`owner/repo`
repoIdGiscus repository ID from giscus.app.`R_xxx`
categoryGitHub Discussions category name.`General`
categoryIdGiscus category ID from giscus.app.`DIC_xxx`
mappingRule for mapping page URL to discussion thread.`pathname`
strictWhether mapping should be strict.`0`
reactionsEnabledEnable GitHub reactions in discussion widget.`1`
emitMetadataEmit metadata to discussion thread.`0`
inputPositionComment input position in widget.`bottom`
themeGiscus theme setting.`preferred_color_scheme`
langGiscus UI language code.`en`
loadingWidget loading behavior.`lazy`
Table: Giscus provider settings

Disqus params ([params.comments.disqus])

ParameterDescriptionExample
shortnameDisqus shortname used to load embed script.`your-disqus-shortname`
Table: Disqus provider settings

Design tokens ([params.design])

ParameterDescriptionExample
fontDisplayDisplay/heading font-family stack.`"Cormorant Garamond", ...`
fontBodyBody text font-family stack.`"Libre Baskerville", ...`
fontUiUI/control font-family stack.`"DM Sans", ...`
radiusSmSmall border radius token.`0.35rem`
radiusMdMedium border radius token.`0.7rem`
containerMaxMax width for wide layout container.`1120px`
contentMaxMax width for main content area.`1000px`
bodyOverlayOpacityOpacity for body background overlay layers.`0.35`
bodyOverlayLinearLinear gradient layer used in page background.`linear-gradient(...)`
bodyOverlayRadialRadial gradient layer used in page background.`radial-gradient(...)`
colorAdmonitionNoteAccent color for note admonitions.`#4f7ca8`
colorAdmonitionTipAccent color for tip admonitions.`#3f8a5f`
colorAdmonitionInfoAccent color for info admonitions.`#2f7d99`
colorAdmonitionWarningAccent color for warning admonitions.`#b77b2e`
colorAdmonitionDangerAccent color for danger admonitions.`#a23b3b`
Table: Global design tokens

Light theme palette ([params.design.light])

ParameterDescriptionExample
colorBgBackground color token for light mode.`#f2ece1`
colorSurfacePrimary surface color in light mode.`#fbf7f0`
colorSurfaceStrongStronger/elevated surface color in light mode.`#f4ede1`
colorTextPrimary text color in light mode.`#1e1a16`
colorMutedMuted text color in light mode.`#6b6158`
colorAccentPrimary accent color in light mode.`#7b2d26`
colorAccentSoftSoft accent color used for highlights.`#bc9a62`
colorBorderBorder color token in light mode.`#d7ccbb`
shadowSoftSoft box-shadow token in light mode.`0 14px 30px ...`
Table: Light-mode color tokens

Dark theme palette ([params.design.dark])

ParameterDescriptionExample
colorBgBackground color token for dark mode.`#151513`
colorSurfacePrimary surface color in dark mode.`#1d1d1a`
colorSurfaceStrongStronger/elevated surface color in dark mode.`#262622`
colorTextPrimary text color in dark mode.`#f3ede3`
colorMutedMuted text color in dark mode.`#c2b7a8`
colorAccentPrimary accent color in dark mode.`#d8926a`
colorAccentSoftSoft accent color used for highlights.`#e7bf78`
colorBorderBorder color token in dark mode.`#3c3a34`
shadowSoftSoft box-shadow token in dark mode.`0 14px 28px ...`
Table: Dark-mode color tokens

Math passthrough params ([markup.goldmark. extensions.passthrough])

ParameterDescriptionExample
enableEnable passthrough delimiters for math content.`true`
Table: Math passthrough settings

Math delimiter params ([markup.goldmark.extensions. passthrough.delimiters])

ParameterDescriptionExample
blockBlock-level math delimiters preserved by Goldmark.`[["$$","$$"],["\\[","\\]"]]`
inlineInline math delimiters preserved by Goldmark.`[["$","$"],["\\(","\\)"]]`
Table: Math delimiter lists

Share this article

  • X
  • Facebook
  • LinkedIn
  • Reddit
  • WhatsApp
  • Telegram
  • Pinterest
  • Bluesky