# DotNetSearch

> DotNetSearch is an MCP server for developer tools. Token-saving code search, NuGet decompilation and deep PDF reading for AI agents. It runs locally on your machine and is started by your AI client.

- **Kind:** MCP server
- **Platforms:** Windows, Linux, macOS, CLI
- **Repository:** https://github.com/puneethdc99/dotnetsearch
- **MCP Registry name:** io.github.puneethdc99/dotnetsearch
- **Categories:** [developer tools](https://ai-powered.com/categories/developer-tools), [files and documents](https://ai-powered.com/categories/files-and-documents)
- **Listing updated:** 2026-11-23

## About

DotNetSearch aims at one problem: agents burn context by reading whole files. Its `search` tool returns only matching lines, about 110 tokens against roughly 2,500 for a full file, and `search_related` finds structurally similar chunks to locate callers and implementations. `compress_code` shrinks C# indentation to one space per level and drops blank lines for a 10 to 20 percent saving.

Its .NET-specific tool is `decompile_type`, which returns the C# definition of a type from referenced NuGet assemblies without the source. A second group of eight tools reads PDFs: text by page range, metadata, page rendering to PNG, embedded images, bookmarks, form fields, attachments and hyperlinks.

Install as a .NET global tool, with `dnx`, or download a self-contained executable for Windows x64, Linux x64 or macOS ARM64. The README includes Copilot instructions that steer GitHub Copilot to prefer it.

## Features

- **Matching-line search:** Returns only matching lines, not whole files.
- **Related code search:** Finds similar chunks to locate callers.
- **NuGet decompilation:** Shows C# type definitions from package assemblies.
- **Code compression:** Cuts indentation and blank lines.
- **PDF text and structure:** Text, metadata, bookmarks and hyperlinks.
- **PDF visuals:** Render pages and extract images.

## Good for

- Find usages in a large .NET solution cheaply
- Read a library type without its source
- Pull a section from a long spec PDF
- Read the fields of an interactive PDF form

## Install

### Claude Code: Add with the CLI (Terminal)

```sh
claude mcp add dotnetsearch -- dnx PuneethDC.DotNetSearch --yes
```

Add --scope user to use it in every project, or --scope project to share it in .mcp.json.

### Claude Code: Or share it with your project (.mcp.json)

```json
{
  "mcpServers": {
    "dotnetsearch": {
      "command": "dnx",
      "args": [
        "PuneethDC.DotNetSearch",
        "--yes"
      ]
    }
  }
}
```

### Claude Desktop (claude_desktop_config.json)

```json
{
  "mcpServers": {
    "dotnetsearch": {
      "command": "dnx",
      "args": [
        "PuneethDC.DotNetSearch",
        "--yes"
      ]
    }
  }
}
```

Settings → Developer → Edit Config, then quit and reopen Claude Desktop.

### Cursor (~/.cursor/mcp.json)

```json
{
  "mcpServers": {
    "dotnetsearch": {
      "command": "dnx",
      "args": [
        "PuneethDC.DotNetSearch",
        "--yes"
      ]
    }
  }
}
```

Use .cursor/mcp.json in a project to share it with the project.

### VS Code (~/.copilot/mcp-config.json)

```json
{
  "mcpServers": {
    "dotnetsearch": {
      "type": "stdio",
      "command": "dnx",
      "args": [
        "PuneethDC.DotNetSearch",
        "--yes"
      ]
    }
  }
}
```

Or put the same entry in .mcp.json at your workspace root to share it.

### Codex: Add with the CLI (Terminal)

```sh
codex mcp add dotnetsearch -- dnx PuneethDC.DotNetSearch --yes
```

### Codex: Or add to config.toml (~/.codex/config.toml)

```toml
[mcp_servers.dotnetsearch]
command = "dnx"
args = ["PuneethDC.DotNetSearch", "--yes"]
```

### Gemini CLI and Antigravity: Gemini CLI (~/.gemini/settings.json)

```json
{
  "mcpServers": {
    "dotnetsearch": {
      "command": "dnx",
      "args": [
        "PuneethDC.DotNetSearch",
        "--yes"
      ]
    }
  }
}
```

Or run: gemini mcp add -s user dotnetsearch dnx -- PuneethDC.DotNetSearch --yes

### Gemini CLI and Antigravity: Antigravity (~/.gemini/config/mcp_config.json)

```json
{
  "mcpServers": {
    "dotnetsearch": {
      "command": "dnx",
      "args": [
        "PuneethDC.DotNetSearch",
        "--yes"
      ]
    }
  }
}
```

Use .agents/mcp_config.json to add it to one workspace only.

### Devin Desktop (~/.config/devin/mcp_config.json)

```json
{
  "mcpServers": {
    "dotnetsearch": {
      "command": "dnx",
      "args": [
        "PuneethDC.DotNetSearch",
        "--yes"
      ]
    }
  }
}
```

On Windows the file is %APPDATA%\\devin\\mcp_config.json. Use .devin/mcp_config.json to share it with a project.

### Cline (cline_mcp_settings.json)

```json
{
  "mcpServers": {
    "dotnetsearch": {
      "command": "dnx",
      "args": [
        "PuneethDC.DotNetSearch",
        "--yes"
      ]
    }
  }
}
```

Open it from the MCP Servers icon → Configure → Configure MCP Servers.

### Zed (Zed settings.json)

```json
{
  "context_servers": {
    "dotnetsearch": {
      "command": "dnx",
      "args": [
        "PuneethDC.DotNetSearch",
        "--yes"
      ]
    }
  }
}
```

Open it with zed: open settings file. Merge context_servers into the settings you already have.

### JetBrains AI Assistant and Junie: AI Assistant (Settings → Tools → AI Assistant → Model Context Protocol (MCP) → Add)

```json
{
  "mcpServers": {
    "dotnetsearch": {
      "command": "dnx",
      "args": [
        "PuneethDC.DotNetSearch",
        "--yes"
      ]
    }
  }
}
```

### JetBrains AI Assistant and Junie: Junie (~/.junie/mcp/mcp.json)

```json
{
  "mcpServers": {
    "dotnetsearch": {
      "command": "dnx",
      "args": [
        "PuneethDC.DotNetSearch",
        "--yes"
      ]
    }
  }
}
```

Use .junie/mcp/mcp.json to share it with a project.

### Kiro (~/.kiro/settings/mcp.json)

```json
{
  "mcpServers": {
    "dotnetsearch": {
      "command": "dnx",
      "args": [
        "PuneethDC.DotNetSearch",
        "--yes"
      ]
    }
  }
}
```

Use .kiro/settings/mcp.json to add it to one workspace only.

### Other clients (your client's MCP settings (most use this shape))

```json
{
  "mcpServers": {
    "dotnetsearch": {
      "command": "dnx",
      "args": [
        "PuneethDC.DotNetSearch",
        "--yes"
      ]
    }
  }
}
```

## Tools

From the tool list in its README, going by the names, 8 of 13 tools read data; 5 names don't say. From the server's own tool labels and tool names; not verified by us.

- `search` (name suggests: reads): Finds files and lines matching a keyword or query.
- `search_related` (name suggests: reads): Finds structurally similar code chunks.
- `decompile_type`: Decompiles a .NET type from NuGet assemblies.
- `compress_code`: Reduces C# indentation and blank lines.
- `read_file` (name suggests: reads): Reads a file or line range.
- `read_pdf_text` (name suggests: reads): Extracts PDF text by page or range.
- `get_pdf_info` (name suggests: reads): Returns PDF metadata and page info.
- `render_pdf_page_as_image`: Renders a PDF page to PNG.
- `extract_pdf_images`: Extracts embedded images.
- `get_pdf_bookmarks` (name suggests: reads): Extracts the outline.
- `get_pdf_form_fields` (name suggests: reads): Reads AcroForm fields.
- `extract_pdf_attachments`: Extracts embedded attachments.
- `get_pdf_hyperlinks` (name suggests: reads): Extracts links with bounding boxes.

## FAQ

### Which clients does DotNetSearch work with?

Visual Studio, VS Code with Copilot, Claude Desktop and Cursor.

### Do I need .NET installed?

Not if you use the standalone executable.

### How much does search save?

The README says about 110 tokens versus 2,500 for a full file read.

### How is DotNetSearch installed?

dotnet tool install -g PuneethDC.DotNetSearch, or dnx.

### How do I add DotNetSearch to Claude Code?

Run this command in your terminal: claude mcp add dotnetsearch -- dnx PuneethDC.DotNetSearch --yes

### What are the best alternatives to DotNetSearch?

The closest alternatives to DotNetSearch are REA, Context7, Chrome DevTools MCP, Codebase Memory and GitHub.

## Where this comes from

- Description: written from the project's README.
- Install steps: from the official MCP Registry entry.

## Alternatives

- [REA](https://ai-powered.com/mcp/rea): REA is an open-source MCP server for developer tools.
- [Context7](https://ai-powered.com/mcp/context7): Context7 is a freemium MCP server for developer tools.
- [Chrome DevTools MCP](https://ai-powered.com/mcp/chrome-devtools-mcp-2): Chrome DevTools MCP is an open-source MCP server for browser automation.
- [Codebase Memory](https://ai-powered.com/mcp/codebase-memory): Codebase Memory is an open-source MCP server for knowledge and memory.
- [GitHub](https://ai-powered.com/mcp/github): GitHub is an open-source MCP server for developer tools.
- [Serena MCP: the IDE for your agent](https://ai-powered.com/mcp/serena-mcp-the-ide-for-your-agent): Serena MCP: the IDE for your agent is an open-source MCP server for developer tools.
- [awesome-mcp-servers](https://ai-powered.com/mcp/awesome-mcp-servers-2): awesome-mcp-servers is an open-source MCP server for developer tools.
- [XERJ](https://ai-powered.com/mcp/xerj): XERJ is an open-source MCP server for knowledge and memory.

---
Source: https://ai-powered.com/mcp/dotnetsearch
