HackTricks MCP Server

Search and query HackTricks pentesting documentation with quick lookup and section extraction

Local serverstdio

What is the HackTricks MCP server?

HackTricks MCP server exists for a simple reason — assistants are far more useful when they can act on HackTricks directly instead of describing what you should do. Search and query HackTricks pentesting documentation with quick lookup and section extraction.

What you get

MCP (Model Context Protocol) server for searching and querying HackTricks pentesting documentation directly from Claude.

  • Quick lookup — - One-shot exploitation info with alias support (sqli, xss, ssrf, etc.)
  • Grouped search results — - Results aggregated by file with match count, title, and relevant sections
  • Page outline — - Quick table of contents to identify relevant sections
  • Section extraction — - Read specific sections instead of full pages (token-efficient)
  • Cheatsheet mode — - Extract only code blocks/commands from pages
  • Category browsing — - Discover available topics and file paths

Setting it up

Installation goes through your MCP client rather than a global install: point it at hacktricks-mcp-server 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.

What the assistant can call

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

  • Installation — The postinstall script automatically clones the HackTricks repository (~2 minutes on first install)
  • hacktricks_quick_lookup — ⚡ One-shot exploitation lookup. Searches, finds best page, and returns exploitation sections + code blocks in one call
  • search_hacktricks — Search through HackTricks documentation. Returns results GROUPED BY FILE with match count, page title, and relevant section headers
  • get_hacktricks_outline — Get the table of contents of a page (all section headers). Use this BEFORE reading full pages to understand structure
  • get_hacktricks_section — Extract a specific section from a page by header name. Much more efficient than reading the full page
  • get_hacktricks_cheatsheet — Extract only code blocks from a page. Perfect when you just need commands, payloads, or examples
  • get_hacktricks_page — The get_hacktricks_page tool exposed by this server
  • list_hacktricks_categories — The list_hacktricks_categories tool exposed by this server

Configuration and credentials

  • Node.js (v18 or higher) - ripgrep (rg) - usually pre-installed on macOS/Linux - Bun (for package management)

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.
  • MCP clients confirm each tool call by default. Leave that on until you have watched what the hacktricks mcp server does with a few real requests.

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. HackTricks's toolset — Installation, hacktricks_quick_lookup, search_hacktricks and 5 more — is a fair guide to whether it matches your workflow. It is maintained by Xplo8E; 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.

Available tools

ToolWhat it does
InstallationThe postinstall script automatically clones the HackTricks repository (~2 minutes on first install).
hacktricks_quick_lookup⚡ **One-shot exploitation lookup**. Searches, finds best page, and returns exploitation sections + code blocks in one call.
search_hacktricksSearch through HackTricks documentation. **Returns results GROUPED BY FILE** with match count, page title, and relevant section headers.
get_hacktricks_outlineGet the **table of contents** of a page (all section headers). Use this BEFORE reading full pages to understand structure.
get_hacktricks_sectionExtract a **specific section** from a page by header name. Much more efficient than reading the full page.
get_hacktricks_cheatsheetExtract **only code blocks** from a page. Perfect when you just need commands, payloads, or examples.
get_hacktricks_pageThe get_hacktricks_page tool exposed by this server.
list_hacktricks_categoriesThe list_hacktricks_categories tool exposed by this server.

How to install the HackTricks MCP server

**Configuration for source install:**

```json
{
  "mcpServers": {
    "hacktricks": {
      "command": "node",
      "args": ["/absolute/path/to/hacktricks-mcp-server/dist/index.js"]
    }
  }
}

Configuration as documented by the project. Restart the client after saving.

Configuration

  • Node.js (v18 or higher) - ripgrep (rg) - usually pre-installed on macOS/Linux - Bun (for package management)

Example prompts to try

  • Use HackTricks to Installation.
  • Use HackTricks to hacktricks quick lookup.
  • Use HackTricks to search hacktricks.

Frequently asked questions

It connects HackTricks to MCP-compatible AI assistants such as Claude and Cursor, exposing 8 tools (Installation, hacktricks_quick_lookup, search_hacktricks, and more) that the assistant can call on your behalf. Instead of copying data back and forth by hand, the assistant works with HackTricks directly.