Dotnet MCP
D

Dotnet MCP

This is a .NET MCP server project that provides AI assistants with direct access to the .NET SDK, supports development tasks such as creating projects, managing packages, and running builds, and simplifies the .NET development process through natural language interaction.
2 points
0

What is the .NET MCP Server?

The .NET MCP Server is a bridge that connects AI assistants to the .NET SDK using the Model Context Protocol (MCP). You can think of it as giving your AI assistant a direct line to the `dotnet` commands, but with intelligence and context understanding. It allows AI assistants to: - Understand the .NET templates and parameters you have installed. - Search for NuGet packages and obtain metadata. - Know the framework version information (including LTS status). - Access your solution and project structure. - Perform operations such as building, testing, and publishing.

How to use the .NET MCP Server?

Using the .NET MCP Server is very simple: 1. Install the server in your development environment (VS Code, Visual Studio, or Claude Desktop). 2. Configure the server to connect to your AI assistant. 3. Start communicating with the AI assistant in natural language and let it help you perform .NET development tasks. The server runs locally, does not send data to external servers, and is completely under your control.

Applicable scenarios

The .NET MCP Server is most suitable for the following scenarios: - Quickly create new .NET projects (Web API, console applications, Blazor, etc.). - Manage NuGet package dependencies and versions. - Execute build, test, and publish processes. - Set up database migrations and Entity Framework configurations. - Manage solution and project structures. - Configure development certificates and security settings. - Explore available .NET templates and tools.

Main features

Template management
Discover, search for, and create .NET project templates, including Web API, Blazor, console applications, etc., and support the configuration of all template parameters.
Project management
Complete project lifecycle management: create, build, run, test, publish, and clean up projects.
Package management
Search for, add, remove, update, and list NuGet packages, and support project-to-project reference management.
Entity Framework Core tools
Database migration management, DbContext operations, database updates, and reverse engineering (database-first development).
Solution management
Create and manage solution files (in .sln and .slnx formats), and add/remove projects to/from the solution.
Tool management
Install, update, uninstall, and run .NET tools (such as dotnet-ef), and support global and local tool manifests.
Security tools
Manage HTTPS development certificates, configure user keys, and automatically desensitize sensitive information for protection.
Code quality
Code formatting, test running, build configuration, and support multi-target framework testing.
Advantages
๐Ÿš€ Faster development speed: Use natural language instead of memorizing complex dotnet commands.
๐Ÿง  Smarter AI assistance: AI can directly access .NET environment information and template metadata.
๐ŸŽฏ Accurate results: Provide suggestions based on the actually installed templates and frameworks, avoiding guesswork errors.
โœจ Consistent results: Use the official .NET SDK API to ensure the reliability of command execution.
๐Ÿ”’ Secure design: Runs locally, automatically desensitizes sensitive information, and does not send data to external servers.
๐Ÿ“Š Structured data: Provide efficient read-only metadata access through MCP resources.
๐Ÿ”„ Concurrent security: Support the AI orchestrator to execute multiple operations in parallel.
Limitations
Requires the .NET 10 SDK for quick installation (manual installation supports earlier versions).
Some advanced features require the installation of additional tools (e.g., Entity Framework requires dotnet-ef).
Depends on the installation and configuration of the local .NET SDK.
For very complex build scenarios, manual configuration may still be required.
Some IDE features (such as Visual Studio-specific features) may not be supported.

How to use

Install the .NET 10 SDK
Ensure that the .NET 10 SDK is installed on your system. This is a requirement for using the quick installation method.
Choose an installation method
Choose the installation method according to your development environment: - VS Code: Click the VS Code installation badge or configure it through the command palette. - Visual Studio: Click the Visual Studio installation badge or configure it through the options. - Claude Desktop: Edit the configuration file to add the MCP server.
Verify the installation
Restart your development environment and then try asking the AI assistant about .NET-related tasks, such as creating a new project.
Start using
Now you can use natural language to let the AI assistant help you perform various .NET development tasks.

Usage examples

Quickly create a Web API project
The user needs to quickly create a new Web API project with basic structure and configuration.
Add a logging package and configure it
The user wants to add structured logging functionality to an existing project.
Database migration management
The user needs to update the database schema after adding a new entity.
Multi-project solution setup
The user needs to create a solution containing multiple projects, such as a microservices architecture.
Package dependency update
The user wants to update all NuGet packages in the project to the latest version.

Frequently Asked Questions

What is the MCP server?
What do I need to install to use this server?
Is this server secure?
Which AI assistants can I use?
What should I do if I encounter the 'dnx not found' error?
Does the server support Entity Framework Core?
Can I run multiple .NET operations simultaneously?
How can I view the tools provided by the server?

Related resources

GitHub repository
Source code, issue tracking, and contribution guidelines
NuGet package
Server NuGet package page
Model Context Protocol official website
Official documentation and specifications for the MCP protocol
.NET download
Download the .NET SDK and runtime
VS Code MCP documentation
Official guide for configuring the MCP server in VS Code
Visual Studio MCP documentation
Microsoft documentation for configuring the MCP server in Visual Studio

Installation

Copy the following command to your Client for configuration
{
  "mcpServers": {
    "dotnet": {
      "command": "dnx",
      "args": ["Community.Mcp.DotNet@1.0.0", "--yes"]
    }
  }
}

{
  "mcpServers": {
    "dotnet": {
      "command": "dotnet",
      "args": ["run", "--project", "/path/to/dotnet-mcp/DotNetMcp/DotNetMcp.csproj"]
    }
  }
}

{
  "mcpServers": {
    "dotnet": {
      "command": "dotnet",
      "args": ["run", "--project", "C:\\path\\to\\dotnet-mcp\\DotNetMcp\\DotNetMcp.csproj"]
    }
  }
}
Note: Your key is sensitive information, do not share it with anyone.

Alternatives

R
Rsdoctor
Rsdoctor is a build analysis tool specifically designed for the Rspack ecosystem, fully compatible with webpack. It provides visual build analysis, multi - dimensional performance diagnosis, and intelligent optimization suggestions to help developers improve build efficiency and engineering quality.
TypeScript
6.7K
5 points
N
Next Devtools MCP
The Next.js development tools MCP server provides Next.js development tools and utilities for AI programming assistants such as Claude and Cursor, including runtime diagnostics, development automation, and document access functions.
TypeScript
6.2K
5 points
T
Testkube
Testkube is a test orchestration and execution framework for cloud-native applications, providing a unified platform to define, run, and analyze tests. It supports existing testing tools and Kubernetes infrastructure.
Go
4.0K
5 points
M
MCP Windbg
An MCP server that integrates AI models with WinDbg/CDB for analyzing Windows crash dump files and remote debugging, supporting natural language interaction to execute debugging commands.
Python
6.5K
5 points
R
Runno
Runno is a collection of JavaScript toolkits for securely running code in multiple programming languages in environments such as browsers and Node.js. It achieves sandboxed execution through WebAssembly and WASI, supports languages such as Python, Ruby, JavaScript, SQLite, C/C++, and provides integration methods such as web components and MCP servers.
TypeScript
5.8K
5 points
P
Praisonai
PraisonAI is a production-ready multi-AI agent framework with self-reflection capabilities, designed to create AI agents to automate the solution of various problems from simple tasks to complex challenges. It simplifies the construction and management of multi-agent LLM systems by integrating PraisonAI agents, AG2, and CrewAI into a low-code solution, emphasizing simplicity, customization, and effective human-machine collaboration.
Python
4.3K
5 points
N
Netdata
Netdata is an open-source real-time infrastructure monitoring platform that provides second-level metric collection, visualization, machine learning-driven anomaly detection, and automated alerts. It can achieve full-stack monitoring without complex configuration.
Go
6.4K
5 points
M
MCP Server
The Mapbox MCP Server is a model context protocol server implemented in Node.js, providing AI applications with access to Mapbox geospatial APIs, including functions such as geocoding, point - of - interest search, route planning, isochrone analysis, and static map generation.
TypeScript
6.4K
4 points
G
Gitlab MCP Server
Certified
The GitLab MCP server is a project based on the Model Context Protocol that provides a comprehensive toolset for interacting with GitLab accounts, including code review, merge request management, CI/CD configuration, and other functions.
TypeScript
20.1K
4.3 points
N
Notion Api MCP
Certified
A Python-based MCP Server that provides advanced to-do list management and content organization functions through the Notion API, enabling seamless integration between AI models and Notion.
Python
17.6K
4.5 points
M
Markdownify MCP
Markdownify is a multi-functional file conversion service that supports converting multiple formats such as PDFs, images, audio, and web page content into Markdown format.
TypeScript
29.6K
5 points
D
Duckduckgo MCP Server
Certified
The DuckDuckGo Search MCP Server provides web search and content scraping services for LLMs such as Claude.
Python
57.8K
4.3 points
F
Figma Context MCP
Framelink Figma MCP Server is a server that provides access to Figma design data for AI programming tools (such as Cursor). By simplifying the Figma API response, it helps AI more accurately achieve one - click conversion from design to code.
TypeScript
53.6K
4.5 points
U
Unity
Certified
UnityMCP is a Unity editor plugin that implements the Model Context Protocol (MCP), providing seamless integration between Unity and AI assistants, including real - time state monitoring, remote command execution, and log functions.
C#
25.0K
5 points
G
Gmail MCP Server
A Gmail automatic authentication MCP server designed for Claude Desktop, supporting Gmail management through natural language interaction, including complete functions such as sending emails, label management, and batch operations.
TypeScript
18.5K
4.5 points
C
Context7
Context7 MCP is a service that provides real-time, version-specific documentation and code examples for AI programming assistants. It is directly integrated into prompts through the Model Context Protocol to solve the problem of LLMs using outdated information.
TypeScript
81.2K
4.7 points