Nuclei MCP server

Integrates with Nuclei vulnerability scanner to automate security assessments through configurable scanning operations with comprehensive reporting for vulnerability analysis and remediation.
Back to servers
Setup instructions
Provider
Mark III Labs
Release date
Mar 08, 2025
Language
Go
Stats
12 stars

Nuclei MCP Integration provides a standardized interface for performing security scans and managing vulnerability assessments programmatically. It integrates Nuclei, a fast and customizable vulnerability scanner, with the Model Context Protocol (MCP) ecosystem to enable efficient security scanning through a well-defined API.

Features

  • Vulnerability scanning using Nuclei's powerful scanning engine
  • Template management for custom Nuclei templates
  • Configurable result caching to optimize repeated scans
  • Thread-safe implementation for high-performance scanning
  • RESTful API for integration with other MCP-compliant tools
  • Detailed vulnerability reports with severity levels and remediation guidance

Installation

Prerequisites

  • Go 1.16+
  • Nuclei (will be automatically downloaded if not present)
  • Node.js 14+ (for MCP Inspector)

Setup Instructions

  1. Clone the repository:

    git clone https://github.com/your-org/nuclei-mcp.git
    cd nuclei-mcp
    
  2. Install dependencies:

    go mod download
    
  3. Start the MCP server:

    go run cmd/nuclei-mcp/main.go
    

Using the MCP Inspector

For development and testing purposes, you can use the MCP Inspector:

# Install the MCP Inspector globally
npm install -g @modelcontextprotocol/inspector

# Start the inspector with the Nuclei MCP server
npx @modelcontextprotocol/inspector go run cmd/nuclei-mcp/main.go

The inspector UI will be available at http://localhost:5173

Configuration

The server can be configured through a YAML configuration file or environment variables. Configuration is loaded from the following locations (in order of precedence):

  1. File specified by --config flag
  2. config.yaml in the current directory
  3. $HOME/.nuclei-mcp/config.yaml
  4. /etc/nuclei-mcp/config.yaml

Sample Configuration File

Create a config.yaml file with the following structure:

server:
  name: "nuclei-mcp"
  version: "1.0.0"
  port: 3000
  host: "127.0.0.1"

cache:
  enabled: true
  expiry: 1h
  max_size: 1000

logging:
  level: "info"
  path: "./logs/nuclei-mcp.log"
  max_size_mb: 10
  max_backups: 5
  max_age_days: 30
  compress: true

nuclei:
  templates_directory: "nuclei-templates"
  timeout: 5m
  rate_limit: 150
  bulk_size: 25
  template_threads: 10
  headless: false
  show_browser: false
  system_resolvers: true

Environment Variables

All configuration options can also be set using environment variables with the NUCLEI_MCP_ prefix. For example:

  • NUCLEI_MCP_SERVER_PORT=3000
  • NUCLEI_MCP_LOGGING_LEVEL=debug

Available Tools

Core Scanning Tools

  • nuclei_scan: Perform a full Nuclei scan with advanced filtering options
  • basic_scan: Quick scan with minimal configuration
  • vulnerability_resource: Query and retrieve scan results

Template Management

  • add_template: Add custom Nuclei templates
  • list_templates: View available templates
  • get_template: Retrieve details of a specific template

Additional Resources

How to install this MCP server

For Claude Code

To add this MCP server to Claude Code, run this command in your terminal:

claude mcp add-json "nuclei" '{"command":"go","args":["run","nuclei_mcp.go"]}'

See the official Claude Code MCP documentation for more details.

For Cursor

There are two ways to add an MCP server to Cursor. The most common way is to add the server globally in the ~/.cursor/mcp.json file so that it is available in all of your projects.

If you only need the server in a single project, you can add it to the project instead by creating or adding it to the .cursor/mcp.json file.

Adding an MCP server to Cursor globally

To add a global MCP server go to Cursor Settings > Tools & Integrations and click "New MCP Server".

When you click that button the ~/.cursor/mcp.json file will be opened and you can add your server like this:

{
    "mcpServers": {
        "nuclei": {
            "command": "go",
            "args": [
                "run",
                "nuclei_mcp.go"
            ]
        }
    }
}

Adding an MCP server to a project

To add an MCP server to a project you can create a new .cursor/mcp.json file or add it to the existing one. This will look exactly the same as the global MCP server example above.

How to use the MCP server

Once the server is installed, you might need to head back to Settings > MCP and click the refresh button.

The Cursor agent will then be able to see the available tools the added MCP server has available and will call them when it needs to.

You can also explicitly ask the agent to use the tool by mentioning the tool name and describing what the function does.

For Claude Desktop

To add this MCP server to Claude Desktop:

1. Find your configuration file:

  • macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
  • Windows: %APPDATA%\Claude\claude_desktop_config.json
  • Linux: ~/.config/Claude/claude_desktop_config.json

2. Add this to your configuration file:

{
    "mcpServers": {
        "nuclei": {
            "command": "go",
            "args": [
                "run",
                "nuclei_mcp.go"
            ]
        }
    }
}

3. Restart Claude Desktop for the changes to take effect

Want to 10x your AI skills?

Get a free account and learn to code + market your apps using AI (with or without vibes!).

Nah, maybe later