Server facts
microsoftdocs mcp
GitHub stars
2,006
Last commit
Nov 13, 2026
Runtime
streamable-http
License
CC-BY-4.0
Project
- Author
- microsoftdocs
- Repository
- github.com/microsoftdocs/mcp
- Website
- learn.microsoft.com
- License
- CC-BY-4.0
- Category
- Memory & Knowledge
Tech
- Transports
- streamable-http
- Remote access
- Yes
- Authentication
- None
Activity
- GitHub stars
- 2,006
- Last commit
- Data as of
Tags
- Documentation
- Rag
- coding
- learn
- microsoft
Overview
Hallucinated Azure SDK parameters, deprecated .NET minimal API patterns, and untrusted blog snippets derail enterprise development quickly. Operated officially by Microsoft (`microsoftdocs/mcp`), the Microsoft Learn MCP Server streams authoritative technical documentation directly to AI agents from `https://learn.microsoft.com/api/mcp` with no authentication, no sign-ups, and no API keys. It exposes three targeted capabilities—`microsoft_docs_search` for semantic retrieval, `microsoft_docs_fetch` to pull full pages as clean markdown, and `microsoft_code_sample_search` for official Microsoft and Azure code snippets with optional language filtering.
Because the endpoint runs remotely over Streamable HTTP, setup requires no local runtime: point VS Code, Cursor, Windsurf, Cline, Roo Code, ChatGPT Developer Mode, Claude Desktop Connectors, or Codex (`codex mcp add`) at `https://learn.microsoft.com/api/mcp`, or install the bundled Claude Code and GitHub Copilot CLI plugins to add guided Agent Skills alongside the endpoint. Visual Studio 2022 (17.13+) and 2026 ship Microsoft Learn built in, so remove duplicate `.mcp.json` entries if marked Eclipsed. Teams needing terminal access without an MCP host can also run `@microsoft/learn-cli` (`mslearn`), while heavy sessions can append `?maxTokenBudget=2000` or use the experimental `/openai-compatible` endpoint.
Install & configure
Requirements
- MCP client supporting Streamable HTTP remote servers (VS Code, Visual Studio 2022 17.13+, Cursor, Claude Desktop, Claude Code, Codex, Windsurf, Cline, or ChatGPT Developer Mode)
- Internet access to https://learn.microsoft.com/api/mcp (no API key or login needed)
- Optional Node.js / npx if using the standalone `@microsoft/learn-cli` (`mslearn`) terminal companion
Configure `https://learn.microsoft.com/api/mcp` as a remote HTTP MCP server in your client, run `/plugin install microsoft-docs@claude-plugins-official` in Claude Code, or use `/plugin install microsoftdocs/mcp` in GitHub Copilot CLI. Opening the URL directly in a browser returns HTTP 405 by design.
Examples are translated from the published configuration. Supply your own credentials and verify requirements in the upstream README. Remote connectors are shown only where a supported configuration format is known.
Config file · macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
Windows: %APPDATA%\Claude\claude_desktop_config.json
Use Settings → Developer → Edit Config when available. Do not assume a Linux configuration path; check the client documentation for your platform. Remote servers use the app’s connector flow when supported, not the local stdio file shown here. Merge this example with existing settings; do not overwrite unrelated servers.
A supported configuration example is not available for this client and transport. Check the client documentation for its connection flow; do not substitute an undocumented JSON format.
Read the Claude Desktop setup guideConfig file · Project: .cursor/mcp.json
User: ~/.cursor/mcp.json
The project path is relative to the workspace root. The tilde denotes your user home directory. Use Cursor’s MCP settings to confirm which configuration and scope your installed version is reading. Merge this example with existing settings; do not overwrite unrelated servers.
{
"mcpServers": {
"microsoft-learn": {
"url": "https://learn.microsoft.com/api/mcp"
}
}
}Config file · Workspace: .vscode/mcp.json
For user scope, use the “MCP: Open User Configuration” command if available. Do not guess a user configuration path across operating systems, profiles, containers, or remote workspaces; check the client documentation. Merge this example with existing settings; do not overwrite unrelated servers.
{
"servers": {
"microsoft-learn": {
"type": "http",
"url": "https://learn.microsoft.com/api/mcp"
}
}
}Config file · macOS/Linux: ~/.codeium/windsurf/mcp_config.json
Windows: %USERPROFILE%\.codeium\windsurf\mcp_config.json
Open the MCP configuration through Windsurf’s settings when possible to confirm the active file. Paths can differ in managed or future releases; check the client documentation if this location is not present. Merge this example with existing settings; do not overwrite unrelated servers.
{
"mcpServers": {
"microsoft-learn": {
"serverUrl": "https://learn.microsoft.com/api/mcp"
}
}
}Config file · Project scope: .mcp.json at the repository root
The project file uses mcpServers. For user scope, use claude mcp add --scope user rather than assuming .mcp.json in your home directory is the user configuration. Check the client documentation for managed settings and storage details. Merge this example with existing settings; do not overwrite unrelated servers.
{
"mcpServers": {
"microsoft-learn": {
"type": "http",
"url": "https://learn.microsoft.com/api/mcp"
}
}
}Examples are translated from the published configuration. Supply your own credentials and verify requirements in the upstream README. Remote connectors are shown only where a supported configuration format is known.
Tools
Source: repository README. Tool descriptions are a documented snapshot, not a live capability check.
| Tool | What it does |
|---|---|
| microsoft_docs_search | Runs semantic search against official Microsoft Learn technical documentation using a text query. |
| microsoft_docs_fetch | Fetches a specific Microsoft documentation URL and converts its full content into markdown. |
| microsoft_code_sample_search | Searches official Microsoft and Azure code samples with an optional programming language filter. |
Use cases
- Verify current Azure CLI flags, managed identity setup, and regional model availability before generating infrastructure scripts.
- Look up accurate .NET 8, ASP.NET Core, Entity Framework, and Azure SDK code samples filtered by programming language.
- Fetch complete Microsoft Learn reference pages as markdown for grounded troubleshooting inside Claude Code or VS Code.
- Query Microsoft documentation from CI scripts or terminals using `npx @microsoft/learn-cli search --json`.
Strengths
- Free, officially hosted by Microsoft over Streamable HTTP with no API keys, accounts, or local installation overhead.
- Restricts retrieval strictly to trusted first-party Microsoft documentation rather than unverified third-party web pages.
- Includes companion `@microsoft/learn-cli` and three portable Agent Skills (`microsoft-docs`, `microsoft-code-reference`, `microsoft-skill-creator`).
Limitations
- Scoped exclusively to Microsoft Learn documentation and Azure/.NET code samples rather than general web search.
- Direct browser visits return HTTP 405 Method Not Allowed because the endpoint requires a compliant Streamable HTTP MCP client.
- Some models skip calling docs tools automatically unless prompted via system rules or the bundled Agent Skills.
microsoftdocs mcp setup notes
- microsoftdocs mcp's example uses http, while its catalog transports are streamable-http; use the example's connection type.