Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Hexo can turn Markdown and other source files into a static documentation site. The practical workflow is to put guide pages in Hexo’s source directory, configure the site’s URL and theme, preview and generate the output, then publish the generated files or connect the project to a hosting provider’s build workflow.

What Hexo does for a documentation site

Hexo is a Node.js static-site framework originally described by its project as a blog framework. Its documentation explains that you write content in Markdown or another supported markup language and Hexo generates static files. That model also suits project documentation: the authored files remain in your repository, and the site is built as HTML, stylesheets, scripts, and other assets for hosting.

Hexo’s project repository lists GitHub Flavored Markdown support, themes and plugins, and deployment options including GitHub Pages. See the Hexo documentation and Hexo project repository for the framework’s current documentation and feature details.

Set up a Hexo project

Install Node.js and Git first. Then install or use the Hexo command-line interface and initialize a site. Hexo’s setup guide documents the generated project structure and installation steps: Hexo setup documentation.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
  1. Initialize a site and install its dependencies:

    hexo init my-docs
    cd my-docs
    npm install

  2. Start with the generated _config.yml and package.json. The project also includes scaffolds, source, and themes.

  3. Put documentation pages and their assets under source. Hexo renders supported content into public; files it does not render are copied there. Posts normally go in source/_posts, while drafts are kept in source/_drafts.

Organize pages and assets

For a documentation site, use source as the content root and group pages into folders that reflect how readers navigate the project. For example, a guide, reference, and troubleshooting section can each have its own directory, with images and downloadable files kept alongside the pages that use them. Keep navigation and directory conventions consistent so contributors can locate and update the right page.

Use front matter at the top of Markdown files for page titles and other metadata used by Hexo or the active theme. Hexo’s new command supports custom slugs and paths, and page creation can produce an index.md. Consult the Hexo commands reference for the supported command options.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

A theme can affect how directory structure appears in the published navigation, so confirm that the theme supports the hierarchy you want rather than assuming source folders automatically become a complete docs menu. Keep custom theme work isolated in the themes directory or in a versioned theme package instead of editing generated output in public.

Configure site URLs and theme settings

The main _config.yml contains site-wide settings such as the title, description, author, language, timezone, URL, root path, permalink format, source and public directories, theme, and deployment configuration. Set the public URL and root path to match the actual hosting location. For a site served below a path such as /docs, configure the full site URL and set root: /docs/; a mismatch can create broken asset or page links even if generation completes successfully. See Hexo configuration for the configuration fields.

Theme-specific values can be placed in theme_config in the main configuration or in a separate _config.[theme].yml file. Hexo documents the precedence order as: main configuration’s theme_config first, the dedicated theme configuration file second, and the theme’s own _config.yml last. This lets a project override theme defaults without modifying the theme itself. The details are in Hexo’s configuration guide.

Choose and maintain a theme

A Hexo theme typically contains an _config.yml, language files, layouts, scripts, and source assets. Layouts define presentation. Hexo uses Nunjucks by default, selects template engines according to file extensions, and can use plugins to add engines such as EJS or Pug; see Hexo theme documentation.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

When evaluating a theme for project documentation, check that it can present the navigation depth and page types your project needs. After applying it, inspect generated navigation, code highlighting, search, and responsive behavior on the actual site. Treat themes and plugins as project dependencies: pin versions, review maintenance activity, and test updates before deploying them.

Preview, generate, and troubleshoot

  1. Start the local preview server with hexo server and open the address it reports. Check page links, assets, navigation, and the site’s appearance at different screen sizes.

  2. Generate the production files with hexo generate. The result is written to public by default.

  3. If the generated site is not right, verify the content’s front matter, the theme configuration, and the configured url and root values. Also check whether a plugin or theme change affects rendering.

    Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
    Best Value
    The SQL Programming Language: .
    • Used Book in Good Condition
  4. For diagnosis, Hexo supports --debug for verbose output and --safe to disable plugins and scripts. The command options are documented in the Hexo commands reference.

Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Support on Ko-Fi

Deploy the generated documentation

Hexo supports deployment workflows, including GitHub Pages; its project repository identifies one-command deployment as a feature. Cloudflare Pages also documents a Hexo setup in which commits to the connected repository can automatically trigger builds and deployments. Choose a workflow based on how your team wants builds and releases to happen, and verify the hosting provider’s current Node.js runtime and project settings before rollout.

Consideration GitHub Pages Cloudflare Pages
Hexo-specific evidence Hexo’s project repository lists GitHub Pages as a deployment target and describes one-command deployment. Cloudflare provides a Hexo setup guide and documents repository-triggered rebuilds and deployments.
Build and release workflow Use Hexo’s documented deployment flow; confirm the current repository and publishing configuration in GitHub’s documentation. Connect the repository and configure the documented Hexo build; commits can trigger deployment.
Custom domains, subdirectory paths, previews, access control, analytics, runtime versions, costs, and support Not stated in the cited Hexo repository source; check current provider documentation and settings for your project. Not stated in the cited Hexo setup source; check current provider documentation and settings for your project.

Use the provider guides to verify current setup details: Hexo one-command deployment and Cloudflare Pages: deploy a Hexo site. For a project hosted under a subdirectory, make the Hexo url and root settings agree with the deployed address before publishing.

Check the version before following older instructions

Hexo’s project site lists releases including Hexo 8.1.0 (2025-10-26), Hexo 8.0.0 (2025-09-16), and Hexo 7.3.0 (2024-07-02). These are dated release announcements, not a guarantee that a particular version is still the latest. Check the Hexo news and release announcements and the current command documentation before relying on instructions written for an older version.

What’s actually slowing this PC down?

Pick the symptom - the matching free tool is one click away.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.