Home / MCP / Perplexity MCP Server
Provides web search via Perplexity API and exposes it to Claude as an MCP server.
Configuration
View docs{
"mcpServers": {
"perplexity_mcp": {
"command": "node",
"args": [
"/absolute/path/to/perplexity-mcp/build/index.js"
],
"env": {
"PERPLEXITY_API_KEY": "your-api-key-here",
"PERPLEXITY_MODEL": "sonar"
}
}
}
}You can run a Perplexity-powered MCP Server that adds web search capabilities to your Claude Desktop workflow. It authenticates with Perplexity’s API and exposes search results to Claude prompts, making it easy to pull in up-to-date information without leaving your chat.
To use this MCP server, configure it in Claude so Claude can invoke the Perplexity search tool automatically. You can then ask Claude questions that require current web information, such as latest news, restaurant recommendations, or historical context, and Claude will retrieve results through Perplexity.
Prerequisites you need before installation are: Node.js (v14 or higher), a Perplexity API key, and the Claude Desktop App.
Installing via Smithery automatically installs the Perplexity MCP for Claude Desktop.
npx -y @smithery/cli install @jaacob/perplexity-mcp --client claudeFor a manual installation, follow these steps in order.
Clone the project and install dependencies.
git clone https://github.com/jaacob/perplexity-mcp
cd perplexity-mcp
npm installBuild the server so you can run the compiled index.
npm run buildObtain your Perplexity API key from Perplexity’s settings page. Then add the MCP server to Claude’s configuration. Create or edit Claude’s config file to include the Perplexity MCP with the following structure.
{
"mcpServers": {
"perplexity_mcp": {
"command": "node",
"args": [
"/absolute/path/to/perplexity-mcp/build/index.js"
],
"env": {
"PERPLEXITY_API_KEY": "your-api-key-here",
"PERPLEXITY_MODEL": "sonar"
}
}
}
}You can choose a Perplexity model by setting the PERPLEXITY_MODEL environment variable. Options include sonar-reasoning-pro, sonar-reasoning, sonar-pro, and sonar (default). If you don’t specify a model, sonar is used by default.
After Claude loads the Perplexity MCP, you can start asking questions that require web search results. If Claude doesn’t automatically use the Perplexity search tool, you can force a web search by prefixing your prompt with "Search the web".
To modify the server, edit the source at src/index.ts, rebuild with npm run build, and restart Claude to load changes.
MIT license.
A tool that queries Perplexity’s web search API and returns relevant results to Claude for display or further prompting.