Skip to content

Instantly share code, notes, and snippets.

@thehappybug
Last active February 7, 2023 19:37
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save thehappybug/bf60be298f3045b482343f1119c391c1 to your computer and use it in GitHub Desktop.
Save thehappybug/bf60be298f3045b482343f1119c391c1 to your computer and use it in GitHub Desktop.
Docusaurus Site SEO Checklist

Docusaurus Site SEO Checklist

Basic SEO checklist when working with Docusaurus

Between the title, description, your pages' links and the pages' content, you have 80% of your SEO covered.

Extended SEO Guidelines

Title

The title should be descriptive. Avoid one word titles. Navigation text and title of the page can be different; you can keep the navigation text short if you want.

Content

Pages with short or shallow content (for e.g, a page with only links) fare badly in search because they don't provide any value to the user. Focus on writing good content. Search engines reward good content that keep the users on the page.

For content heavy sites like documentation or guide/references, you should remove the landing pages which only contain illustrations or cards because they brings no value to the user. Rather, focus on getting user to the sticky content as fast as you can.

Your main page should serve as a both a summary and an index for the user. It should also be inviting.

Hook

We need to have at least one good Hook Page, something that convinces people why this site is important. Ideally, it should be the first page. If the first page is primarily a summary or index page, then the Hook page should be the second page. If I send anyone the link to the site, it will be that page so it has to be convincing enough that the reader would want to engage with the rest of the time.

Theme

A new Docusaurus site looks quite bland. It is easily recognisable as a default-themed Docusaurus website. Also, the default theme is quite blockly, flat which doesn't help. You should style this as soon as possible. Things to change: font, content width, sidebar styling, primary and secondary colors. Branding does matter.

Marketing

You should put the "Built with ❤️ by Company Name" at the top-right on the navbar. You should also add it to the footer.

The GitHub repo link on the top-right can be removed. It is not a primary function for most people and the contributors can already find the repo by following the edit button on the page and the Github repo link in the footer of the pages.

Search

You should enable Algolia search on your site. Doc readers/users have come to expect docs site to have a integrated search; the Ctrl-K shortcut is a common shortcut to bind your search function to.

Social

For a self-marketing site, you need to optimize for social as well and the first thing that comes to my mind when it comes to social sharing is that people see a preview of the page when they link to your site or embed it in a post. The preview banner or image is crucial for visiblity; it is usually bigger than the page title itself on most social sites and is an oppurtunity to grab eyeballs. You can set this using the image frontmatter property. However, you do need to create these images. There will be one image per page. I found some services that attempt to automate creating these images based on a customizable template. For example, here's one.

Things Docusaurus Already Handles For You

  • HTML pages that are static. Search engines love static sites because they are easy to crawl. Users love them because behind a CDN like Cloudflare, static sites are blazing fast.
  • Sitemap file. Search engines use this to discover pages.
  • Structured content. Write consitent Markdown and Docusaurus will create HTML with the correct semantic markup.
  • Light and dark mode themes. Do make sure to adapt the dark mode theme in case you're customzing the site's theme.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment