Should Hugo include Jekyll/GitHub-like SEO?

This page at GitHub describes a new feature in Jekyll which helps pages hosted on GitHub be more visible to search-engines, if you just add the tag {% seo %}.

I don’t want to suggest work for other people, but perhaps this could be an interesting addition for Hugo?

Hello @chreliot,

Hugo already has some built-in templates for SEO. They aren’t documented right now (don’t ask me why) but they are usable.


Interesting. How do you use this, exactly ?

You can include them via

 {{ template "_internal/<TEMPLATENAME>.html" . }}

There is an entire discussion about the implementation and design of these templates.


Thanks !

One pitfall of jekyll-seo-tag is its inability to be reused more than once per page.

Such reuse becomes a limitation when outputting structured data in a list page, such as a post archive, where each article output would be better served by including some metadata about it.

Hugo can output structured data multiple times per page in a loop given the structure of its internal templates. I’ve provided an example of how to do this in the After Dark theme.

Keeping schema-related internal templates reusable multiple times per page is something to keep an eye out for as internal templates are updated in Hugo over time—I’ve already put the kibosh on one attempt to update them in a way which would only allow a single use per page.

1 Like