Perplexity Tool for Claude Desktop
This server enables Claude Desktop to interact with Perplexity AI for web-based research with citations. You can:
Ask Questions: Submit queries to Perplexity AI for detailed answers
Control Response Length: Limit response size with the
max_tokensparameterAdjust Randomness: Modify response creativity using the
temperatureparameter (0-2)Filter by Domain: Restrict search results to specific domains with
search_domain_filterFilter by Recency: Narrow results to specific timeframes (day, week, month, year) using
search_recency_filter
Provides support for storing Perplexity API keys securely in environment variables for better security practices when sharing code.
Allows Claude to perform web-based research through Perplexity AI's API, providing answers with citations. Supports configuration of parameters like temperature, max tokens, domain filtering, and recency filtering.
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@Perplexity Tool for Claude Desktopresearch the latest breakthroughs in quantum computing from the past year"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
Perplexity Tool for Claude Desktop
A custom MCP tool that integrates Perplexity AI's API with Claude Desktop, allowing Claude to perform web-based research and provide answers with citations.
Prerequisites Installation
Install Git:
For Mac:
Install Homebrew first by pasting this in Terminal:
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"Then install Git:
brew install gitFor Windows:
Download Git from git-scm.com
Run the installer
Install Node.js:
For Mac:
brew install nodeFor Windows:
Download from nodejs.org
Run the installer
Verify installations by running:
git --version
node --versionRelated MCP server: Perplexity MCP Server
Tool Installation
Clone the repository
git clone https://github.com/letsbuildagent/perplexity-tool
cd perplexity-toolInstall dependencies
npm installSet up your API Key
You have two options:
Option 1 (Quick setup):
Open
server.jsFind this line:
const PERPLEXITY_API_KEY = "YOUR-API-KEY-HERE";Replace with your Perplexity API key
Option 2 (Best practice):
Create a .env file:
# On Mac/Linux: touch .env open .env # On Windows: notepad .envOr simply create a new file named
.envin your text editorAdd your API key to the .env file:
PERPLEXITY_API_KEY=your-api-key-hereInstall dotenv:
npm install dotenvUpdate server.js:
import 'dotenv/config' const PERPLEXITY_API_KEY = process.env.PERPLEXITY_API_KEY;
Configure Claude Desktop
Open
~/Library/Application Support/Claude/claude_desktop_config.jsonAdd this configuration:
{
"mcpServers": {
"perplexity-tool": {
"command": "node",
"args": [
"/full/path/to/perplexity-tool/server.js"
]
}
}
}Replace /full/path/to with the actual path where you cloned the repository.
Restart Claude Desktop
Usage
Once installed, you can use the tool through Claude with commands like:
"Ask Perplexity about recent developments in AI"
"Use Perplexity to research the history of quantum computing"
"Search Perplexity for information about climate change, focusing on the last month"
Advanced Options
You can specify additional parameters:
temperature: Controls response randomness (0-2)max_tokens: Limits response lengthsearch_domain_filter: Restricts search to specific domainssearch_recency_filter: Filters by time period (day/week/month/year)
Troubleshooting
Git not found:
Make sure you've installed Git correctly
Try restarting your terminal
On Mac, make sure Homebrew is in your PATH
Node.js errors:
Verify Node.js installation with
node --versionTry reinstalling Node.js
API Key issues:
Make sure you've correctly copied your API key
Check that there are no extra spaces in your .env file
If using Option 2, verify dotenv is installed
Tool not appearing in Claude:
Check the path in claude_desktop_config.json
Make sure the path points to your server.js file
Restart Claude Desktop
Check the console for any error messages
License
MIT
Security Note
If you're planning to share your code or make it public:
Don't commit your API key to Git
Use the .env method (Option 2)
Add .env to your .gitignore file
Available Tools
1 toolask_perplexityC
Ask a question to Perplexity AI
| Name | Required | Description | Default |
|---|---|---|---|
| question | Yes | The question to ask | |
| temperature | No | Response randomness (0-2) | |
| max_tokens | No | Maximum tokens in response | |
| search_domain_filter | No | Limit search to specific domains | |
| search_recency_filter | No | Filter results by recency | month |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations are provided, so the description carries the full burden of behavioral disclosure. It states the tool 'Ask a question to Perplexity AI,' which implies it's a query tool, but doesn't describe what happens—e.g., whether it performs web searches, generates responses, has rate limits, or requires authentication. This is a significant gap for a tool with multiple parameters and no output schema.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single, clear sentence with no wasted words. It's front-loaded and efficiently conveys the core action, making it easy to scan and understand quickly.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the complexity (5 parameters, no annotations, no output schema), the description is incomplete. It doesn't explain what the tool returns, how it behaves (e.g., search-based vs. generative), or any constraints. The agent must rely heavily on the schema and tool name, which is insufficient for effective use.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The input schema has 100% description coverage, so parameters like 'question,' 'temperature,' and 'search_recency_filter' are well-documented in the schema. The description adds no additional meaning beyond the schema, such as explaining how parameters interact or typical use cases. This meets the baseline of 3 since the schema does the heavy lifting.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description 'Ask a question to Perplexity AI' clearly states the action (ask) and target (Perplexity AI), which is adequate. However, it's somewhat vague about what Perplexity AI is or does—it doesn't specify if this is for general queries, research, or something else. With no sibling tools, differentiation isn't needed, but the purpose could be more specific.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description provides no guidance on when to use this tool—it doesn't mention use cases, prerequisites, or alternatives. With no sibling tools, there's no need to differentiate, but it lacks any context for appropriate usage, leaving the agent to infer based on the tool name alone.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections. Dates show when Glama detected each change.
1 tool update
v1.0.0- Added
ask_perplexity
TDQS
With only one tool, there is no possibility of ambiguity or overlap between tools. The single tool 'ask_perplexity' has a clearly distinct purpose that cannot be confused with any other tool in this server.
The single tool name follows a clear verb_noun pattern ('ask_perplexity'), and with only one tool, there is perfect consistency. No other naming conventions exist to create inconsistency.
A single tool is generally too few for most server purposes, as it provides minimal functionality and limits agent capabilities. For a Perplexity AI integration, one tool might suffice for basic queries, but it feels thin and lacks operations like follow-up questions or context management.
The tool surface is severely incomplete for interacting with Perplexity AI. While 'ask_perplexity' covers basic queries, there are significant gaps such as no support for conversation history, context setting, or handling different query types, which will likely cause agent failures in complex tasks.
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Connectors
Live AI-native web search with citations. One tool for every MCP client. Flat per-request pricing.
Real-time web search, reasoning, and research through Perplexity's API
Web search, scraping, RAG answers with citations, and translation as MCP tools.
- QuallaaOAuthcom.quallaa
Talk to your public-facing AI from any MCP client — Claude, ChatGPT, Cursor, Cline, Windsurf.
Related MCP Servers
- AlicenseAqualityDmaintenanceAn MCP server that enables Claude to perform web searches using Perplexity's API with intelligent model selection based on query intent and support for domain and recency filtering.64MIT
- AlicenseAqualityDmaintenanceMCP server that enables Claude to request chat completions with citations from the Perplexity API.1MIT
- FlicenseAqualityDmaintenanceIntegrates Perplexity AI's search-enhanced language models with Claude Desktop, providing three tools with different complexity levels for quick fact-checking, technical analysis, and deep research.32-
- FlicenseNot gradedqualityDmaintenanceIntegrates Perplexity API into Claude/Cowork as MCP tools for search, trend scouting, and deep research.-
Appeared in Searches
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/letsbuildagent/perplexity-tool'
If you have feedback or need assistance with the MCP directory API, please join our Discord server