Perplexity

Perplexity

An MCP server that connects to Perplexity's Sonar API, enabling real-time web-wide research in conversational AI.

1,789
Stars
253
Forks
0
Releases

Overview

The Perplexity MCP Server is the official server implementation for the Perplexity API Platform, enabling AI assistants to access real-time web search, reasoning, and research capabilities through Sonar models and the Perplexity Search API. It exposes four primary tools: perplexity_search for direct web search returning ranked results with metadata; perplexity_ask for general-purpose conversational AI with real-time web search using the sonar-pro model; perplexity_research for deep, comprehensive research using sonar-deep-research; and perplexity_reason for advanced reasoning with sonar-reasoning-pro. Optional strip_thinking can be enabled to remove <think>...</think> tags and reduce token usage for perplexity_reason and perplexity_research. Deployment is flexible: run an HTTP server with environment variables such as PERPLEXITY_API_KEY, PORT, BIND_ADDRESS, and ALLOWED_ORIGINS; Docker and Node.js workflows are provided; and multiple MCP clients (Cursor, Claude, VS Code, Codex, Claude Desktop) can connect via standard MCP configurations. The README covers API key setup, plugin vs manual configuration, proxy options (PERPLEXITY_PROXY or HTTPS_PROXY/HTTP_PROXY), and troubleshooting, including endpoint details such as the /mcp path.

Details

Owner
ppl-ai
Language
TypeScript
License
MIT License
Updated
2025-12-07

Features

perplexity_search

Direct web search using the Perplexity Search API, returning ranked results with metadata.

perplexity_ask

General-purpose conversational AI with real-time web search using the sonar-pro model.

perplexity_research

Deep, comprehensive research using the sonar-deep-research model for detailed analyses.

perplexity_reason

Advanced reasoning and problem-solving using the sonar-reasoning-pro model.

Strip thinking (strip_thinking)

Optional parameter for perplexity_reason and perplexity_research to remove <think>...</think> tags and save tokens; default is false.

HTTP server deployment

Run in HTTP mode with PORT, BIND_ADDRESS, ALLOWED_ORIGINS, and PERPLEXITY_API_KEY; includes Docker and Node.js setup and /mcp endpoint.

Proxy support

Supports PERPLEXITY_PROXY as well as HTTPS_PROXY/HTTP_PROXY with a defined precedence order.

Multi-client integration

Connects with various MCP clients (Cursor, Claude Code, VS Code, Codex, Claude Desktop) via standard MCP configuration.

Audience

MCP developersIntegrate Perplexity-powered web search and Sonar models into MCP-enabled assistants.
Product teamsEnable real-time web research and answering capabilities in AI assistants deployed via MCP.
ResearchersLeverage deep research tools and reasoning models for analysis and reporting through MCP.

Tags

PerplexityMCPAI assistantWeb searchSonar modelsSearch APIReal-time researchReasoningProxy supportHTTP serverDocker