Hugo MCP Server

✏️ Plug-and-play binary wrapper for Hugo Extended, the awesomest static-site generator.

Local serverstdioTypeScript

What is the Hugo MCP server?

Hugo MCP server exists for a simple reason — assistants are far more useful when they can act on Hugo directly instead of describing what you should do. ✏️ Plug-and-play binary wrapper for Hugo Extended, the awesomest static-site generator.

What you get

These integrate seamlessly with Hugo's built-in PostCSS pipes.

  • 🚀 Zero configuration — Hugo binary is automatically downloaded on install
  • 📦 Version-locked — Package version matches Hugo version (e.g., hugo-extended@0.140.0 = Hugo v0.140.0)
  • 🔒 Type-safe API — Full TypeScript support with autocomplete for all Hugo commands and flags
  • Multiple APIs — Use CLI, function-based, or builder-style APIs
  • 🎯 Extended by default — Automatically uses Hugo Extended on supported platforms

What the assistant can call

Once Hugo is connected, these are the calls the assistant has available:

  • build — hugo.build()
  • server — hugo.server()
  • new — hugo.new()
  • config — hugo.config()
  • version — hugo.version()
  • env — hugo.env()
  • Examples — The Examples tool exposed by this server

Configuration and credentials

You will need 3 environment variables: DEPLOY_PRIME_URL, HUGO_BIN_PATH, HUGO_MIRROR_BASE_URL. The server will not start without them, which is usually why the tools fail to appear on a first run. Keep credentials in your client's env block or a secrets manager rather than in a file you might commit.

Setting it up

Installation goes through your MCP client rather than a global install: point it at hugo-extended on npm and it is fetched when the client starts. The copy-paste blocks for Claude Desktop, Claude Code and Cursor are further down this page.

Choosing this one

Among the developer tooling options, the useful question is rarely "what can it do" but "what does it cost you to run" — permissions, credentials, and how much of your context its toolset consumes. Hugo's toolset — build, server, new and 4 more — is a fair guide to whether it matches your workflow. It is maintained by GitHub Actions; worth a glance at recent repository activity before you build anything load-bearing on it.

SyncDev reviews every entry in this directory against the project's own documentation before publishing, and revisits them as servers change.

Before you rely on it

  • It runs with your machine's permissions. That is convenient and also the reason to think about what you point it at before you approve a tool call.
  • Missing credentials fail quietly in some clients — if no tools show up, check the environment block first.
  • MCP clients confirm each tool call by default. Leave that on until you have watched what the hugo mcp server does with a few real requests.

Available tools

ToolWhat it does
buildhugo.build()
serverhugo.server()
newhugo.new()
confighugo.config()
versionhugo.version()
envhugo.env()
ExamplesThe Examples tool exposed by this server.

How to install the Hugo MCP server

{
  "mcpServers": {
    "hugo": {
      "command": "npx",
      "args": ["-y", "hugo-extended"],
      "env": {
        "DEPLOY_PRIME_URL": "your-value",
        "HUGO_BIN_PATH": "your-value",
        "HUGO_MIRROR_BASE_URL": "your-value"
      }
    }
  }
}

Add to claude_desktop_config.json, then restart Claude Desktop.

Configuration

VariableDescriptionRequired
DEPLOY_PRIME_URLEndpoint or connection string the server talks to.Yes
HUGO_BIN_PATHFilesystem location the server is allowed to use.Optional
HUGO_MIRROR_BASE_URLEndpoint or connection string the server talks to.Yes

Example prompts to try

  • Use Hugo to build.
  • Use Hugo to server.
  • Use Hugo to new.

Frequently asked questions

It connects Hugo to MCP-compatible AI assistants such as Claude and Cursor, exposing 7 tools (build, server, new, and more) that the assistant can call on your behalf. Instead of copying data back and forth by hand, the assistant works with Hugo directly.