Pby Perplexity
Search the web
Returns ranked web results for a query, each with its title, URL, snippet and dates, optionally limited to domains or a date range.
Description
On the CLI, `-n` sets the number of results (10 by default), and `--domains`, `--recency-filter`, the date flags and `--country` apply the Search API's filters. Extra queries on the CLI are rephrasings of one question, not separate searches, and come back as a single ranked list.
search-web.md
Search the web
Returns ranked web results for a query, each with its title, URL, snippet and dates, optionally limited to domains or a date range.
On the CLI, -n sets the number of results (10 by default), and --domains,
--recency-filter, the date flags and --country apply the Search API's
filters. Extra queries on the CLI are rephrasings of one question, not separate
searches, and come back as a single ranked list.
Set up
Use the first option your agent supports.
MCP (official, remote)
Add this server to your agent's MCP settings, then sign in when asked.
{ "mcpServers": { "perplexity": { "url": "https://api.perplexity.ai/mcp" } } }
Call the MCP tool perplexity_search.
Server URL: https://api.perplexity.ai/mcp
CLI (official)
Install the command, then confirm it runs.
curl -fsSL https://github.com/perplexityai/perplexity-cli/releases/latest/download/install.sh | sh
pplx --version
Run pplx search web.
Set $PERPLEXITY_API_KEY in your environment first (get a key: https://console.perplexity.ai/project/keys).
API (official)
- Base URL: https://api.perplexity.ai
- Endpoint:
POST /search - Auth: send the header
Authorization: Bearer $PERPLEXITY_API_KEY - Get a key: https://console.perplexity.ai/project/keys
- Docs: https://docs.perplexity.ai/docs/getting-started/overview
Before doing anything else, make one read-only call to confirm access.
Rules
- Ask the user before anything that sends messages, costs money, or changes data.
- Never print API keys.
Built from these files in the repository
The layout and the rules come from lib/catalog/render-markdown.ts, the set-up wording from lib/catalog/render-access.ts.