Skip to content
MCP server

PnP PowerShell

Manage Microsoft 365 in natural language with PnP PowerShell and author PnP PowerShell…

Runs locallyStatus and history
Install
Pricing
Open source
Runs
Locally
Version
0.1.7-beta
Listing updated
5 days ago

About PnP PowerShell

PnP PowerShell is an open-source MCP server. It runs locally on your machine and is started by your AI client.

Manage Microsoft 365 in natural language with PnP PowerShell and author PnP PowerShell scripts.

Install

Run in a terminal

claude mcp add pnp-powershell-mcp-server -- dnx PnP.PowerShell.MCPServer --yes

Add to claude_desktop_config.json

{
  "mcpServers": {
    "pnp-powershell-mcp-server": {
      "command": "dnx",
      "args": [
        "PnP.PowerShell.MCPServer",
        "--yes"
      ]
    }
  }
}
Install in CursorOpens Cursor, which asks you to confirm. Or add it by hand:

Add to ~/.cursor/mcp.json

{
  "mcpServers": {
    "pnp-powershell-mcp-server": {
      "command": "dnx",
      "args": [
        "PnP.PowerShell.MCPServer",
        "--yes"
      ]
    }
  }
}
Install in VS CodeOpens VS Code, which asks you to confirm. Or add it by hand:

Add to .vscode/mcp.json

{
  "servers": {
    "pnp-powershell-mcp-server": {
      "type": "stdio",
      "command": "dnx",
      "args": [
        "PnP.PowerShell.MCPServer",
        "--yes"
      ]
    }
  }
}

Add to ~/.codeium/windsurf/mcp_config.json

{
  "mcpServers": {
    "pnp-powershell-mcp-server": {
      "command": "dnx",
      "args": [
        "PnP.PowerShell.MCPServer",
        "--yes"
      ]
    }
  }
}

Add to your client's MCP settings (most use this shape)

{
  "mcpServers": {
    "pnp-powershell-mcp-server": {
      "command": "dnx",
      "args": [
        "PnP.PowerShell.MCPServer",
        "--yes"
      ]
    }
  }
}

Using several servers? Build one config file with the MCP config generator.

Configuration

  • PNP_MCP_READONLYRead-only mode: true refuses every command that would change Microsoft 365.
  • PNP_MCP_ALLOW_SETUPtrue lets pnp_setup_environment install the PnP.PowerShell module for the current user when it is missing.

Pricing

Open source

PnP PowerShell FAQ

Is PnP PowerShell free?

Yes. PnP PowerShell is open source, so you can use and self-host it for free.

How do I add PnP PowerShell to Claude Code?

Run this command in your terminal: claude mcp add pnp-powershell-mcp-server -- dnx PnP.PowerShell.MCPServer --yes

Where this comes from

  • Description: from the official MCP Registry entry.
  • Install steps: from the official MCP Registry entry.

How AIPoweredBot checks servers