Microsoft Learn MCP logo

Microsoft Learn MCP

Search Microsoft Learn documentation and official code samples, then fetch pages as Markdown through a remote MCP endpoint.

Install Microsoft Learn MCP

Pick your client, then add it in one click or paste the config.

STDIONode.js
~/Library/Application Support/Claude/claude_desktop_config.json
claude_desktop_config.json
{
  "mcpServers": {
    "microsoft-learn-mcp": {
      "command": "npx",
      "args": [
        "-y",
        "@microsoft/learn-cli"
      ]
    }
  }
}

Settings → Developer → Edit Config, merge this into mcpServers, then fully quit and reopen Claude Desktop.

We couldn’t confirm it starts correctly

The install command installed and started the server, which then stopped for configuration (such as an API key) that our sandbox does not have — expected for servers that connect to your account.

npx -y @microsoft/learn-cli

No response to initialize.

This is an experimental automated check and can have false negatives — missing environment variables, a slow cold install, etc. It doesn’t necessarily mean something’s wrong. Last checked 20d ago.

Overview

Microsoft Learn MCP MCP server gives MCP-compatible AI clients access to official Microsoft documentation and code samples. It provides tools for semantic documentation search, page retrieval as Markdown, and Microsoft/Azure code-sample search with an optional language filter. Connect through the remote Streamable HTTP endpoint without an API key. Reach for it when an agent needs current Microsoft guidance, API details, configuration instructions, or verified examples.

Use cases

  • Search Microsoft documentation for Azure configuration guidance
  • Fetch a Microsoft Learn page as Markdown for an AI agent
  • Find official Azure code samples by programming language
  • Verify Microsoft API usage against current first-party documentation

Key features

  • Semantic search across official Microsoft documentation
  • Markdown conversion for Microsoft Learn pages
  • Search for official Microsoft and Azure code samples
  • Optional programming-language filtering
  • Remote Streamable HTTP access without an API key
  • Experimental OpenAI-compatible endpoint

Security & health

What it can reach and how reliably it runs — from our own checks, not the maintainer’s claims.

ActiveLast checked Today

Recent health check succeeded.

50/53 checks healthy over the last 91d

Supply-chain signal

No high-severity advisories surfaced by our automated scan.

Critical 0High 0Medium 0Low 0

Scanned 3d ago via OSV.dev · @microsoft/learn-cli (npm)

Adoption & maintenance

Factual signals from GitHub, npm, and our automated checks — not a rating.

GitHub stars1kStargazers on the source repository.
npm downloads1.9kPackage downloads in the last 30 days.
Last commit10d agoMost recent push to the default branch.
Install checkRunsOur sandbox started it; it then asked for an API key or config.
Directory activity1 viewsConfig copies, upvotes, and views on AllMCPs.

How Microsoft Learn MCP works

What the Microsoft Learn MCP MCP server does

Microsoft Learn MCP MCP server connects compatible AI clients to official Microsoft technical documentation hosted by Microsoft Learn. It supports documentation discovery, page retrieval, and code-example lookup without requiring a separate search engine or local documentation index.

The service is intended for coding and technical research tasks involving Microsoft technologies, including Azure and .NET. Agents can use it to answer questions about concepts, configuration, APIs, commands, supported features, and implementation examples. Results come from Microsoft’s first-party documentation rather than general web sources.

How it works

The Microsoft Learn MCP MCP server is available as a remote Streamable HTTP service at https://learn.microsoft.com/api/mcp. A compatible MCP client sends tool calls to that endpoint and receives search results or converted documentation content. Opening the URL directly in a browser is not the intended access method and may return 405 Method Not Allowed.

Three tools are documented:

  • microsoft_docs_search performs semantic search using a text query.
  • microsoft_docs_fetch retrieves a specified Microsoft documentation URL and converts the page to Markdown.
  • microsoft_code_sample_search looks for official Microsoft or Azure code examples. It accepts a query and an optional programming-language filter.

An experimental OpenAI-compatible endpoint is available at https://learn.microsoft.com/api/mcp/openai-compatible for applications that require compatibility with OpenAI Deep Research models. The endpoint also supports an experimental maxTokenBudget query parameter, which limits the amount of content returned by search responses.

Setup and configuration

The Microsoft Learn MCP MCP server uses this standard configuration:

config.json
{
  "servers": {
    "microsoft-learn": {
      "type": "http",
      "url": "https://learn.microsoft.com/api/mcp"
    }
  }
}

No API key, login, or sign-up is required according to the project documentation. VS Code provides an install link for the service, and the endpoint can also be configured in other MCP-compatible clients. Experimental endpoint behavior and token-budget controls may change.

The repository also publishes @microsoft/learn-cli, which exposes the same search, fetch, and code-sample functions from a terminal without an MCP client. Its setup commands can add CLI-first discovery for GitHub Copilot, Claude Code, or Codex, but that workflow does not configure MCP for clients such as Cursor.

Tools and capabilities

Use documentation search when an agent needs to locate relevant Microsoft Learn pages from a natural-language question. Fetch a known page when the agent needs the complete content in Markdown. Use code-sample search to find Microsoft or Azure examples and narrow results by programming language.

The repository includes agent skills for Microsoft documentation concepts and tutorials, API and code-reference work, and creating custom skills for Microsoft technologies. These skills guide tool selection but are separate from the three MCP tools themselves.

Limitations and notes

The service only exposes the tools and content described by the project: Microsoft documentation and official Microsoft/Azure code samples. It is not presented as a general web-search service. Direct browser requests to the MCP URL are unsupported.

The OpenAI-compatible endpoint and maxTokenBudget parameter are experimental. Their behavior may change as development continues. Installing the Learn CLI does not automatically configure an MCP client, and CLI discovery setup is limited to the documented Copilot, Claude Code, and Codex plugin ecosystems.

Reviews

No reviews yet — be the first to share how it worked for you.

Frequently Asked Questions about Microsoft Learn MCP

Microsoft Learn MCP is an MCP server that connects MCP-compatible AI clients to official Microsoft Learn documentation. Its main tools search Microsoft technical docs, fetch documentation pages as Markdown, and find official Microsoft/Azure code samples, with an optional programming-language filter for code searches. It uses a remote Streamable HTTP endpoint and needs no API key.

Configure your MCP client with the remote URL `https://learn.microsoft.com/api/mcp`; no API key or login is required. VS Code provides a one-click installation link, while other compatible clients can use the standard HTTP server configuration shown in the repository.

It provides three tools: `microsoft_docs_search` for semantic documentation queries, `microsoft_docs_fetch` for converting a specified Microsoft page to Markdown, and `microsoft_code_sample_search` for finding official Microsoft or Azure examples with an optional language filter.

Yes, Cursor is named as a supported use case for the remote MCP endpoint. Add `https://learn.microsoft.com/api/mcp` as an HTTP MCP server in Cursor using the standard configuration; the repository also notes that its CLI setup does not configure Cursor.

No, the documented remote endpoint requires no API key, login, or sign-up. Configure an MCP-compatible client to use `https://learn.microsoft.com/api/mcp` over Streamable HTTP.

Related MCP servers

Add a badge to your READMEShow it’s listed — live SVG, Markdown or HTML.

AllMCPs Directory Badge

Full Badge Customizer

Showcase your server listing on GitHub or your project documentation. Embed this dynamic SVG badge to highlight official listing status and live engagement.

Badge Style:
Live Dynamic SVG PreviewMicrosoft Learn MCP AllMCPs Directory Badge
Markdown (GitHub README)
[![AllMCPs](https://allmcps.com/api/badge/microsoft-learn-mcp?style=directory)](https://allmcps.com/mcp/microsoft-learn-mcp)
HTML Embed
<a href="https://allmcps.com/mcp/microsoft-learn-mcp"><img src="https://allmcps.com/api/badge/microsoft-learn-mcp?style=directory" alt="Microsoft Learn MCP on AllMCPs" /></a>