---
last_updated: 2026-11-27
source_url: https://opper.ai/perplexity/sonar
title: "Perplexity Sonar by Perplexity"
description: "Perplexity Sonar: lightweight real-time web search model for quick factual queries and summarization, with a 128K context window."
---

# Perplexity Sonar

By [Perplexity](https://opper.ai/perplexity).

Released 21 Jan 2025 · [All Perplexity releases](https://opper.ai/model-releases/perplexity)

Sonar is Perplexity's lightweight search model built for speed and efficiency. It delivers grounded answers with real-time web search and citations, making it well suited to straightforward informational tasks like fact-checking, current events, and quick summaries. The model supports text input and structured output generation.

It is best for fast information retrieval and quick definitions rather than deep analytical work. Its 128K context window handles substantial conversations while keeping responses fast.

## Available routes

Perplexity Sonar runs on 2 different routes through the Opper gateway. Prices are per 1M tokens. Its routes and prices, live from the catalogue, are public JSON with no API key needed at https://api.opper.ai/v3/models?q=perplexity-agent%2Fsonar.

| Provider | Model id | Region | Zero data retention | Training | Input | Output | Cache read |
| --- | --- | --- | --- | --- | --- | --- | --- |
| [Perplexity](https://opper.ai/provider/perplexity) | `perplexity-agent/sonar` | Multi-region | Retained | No | $0.25 | $2.50 | $0.06 |
| [Perplexity](https://opper.ai/provider/perplexity) | `perplexity/sonar` | US (United States) | Yes | No | $1.00 | $1.00 | Input price |

## Key info

- Model id: `perplexity-agent/sonar`
- Input: Text, Image
- Output: Text
- Features: Tools, Structured output
- Context window: 128K
- Max output: 8K
- Input price: $0.25 per 1M tokens ($0.06 cache read)
- Output price: $2.50 per 1M tokens
- Released: 21 Jan 2025
- US residency available on Perplexity
- Zero data retention on pay-as-you-go
- No training by default

## Data handling per route

Each route hosting Perplexity Sonar has its own privacy posture, residency, and GDPR terms. Postures are maintained by Opper with a last-verification timestamp.

### Perplexity — Multi-region

Content is retained: provider logging. No training on customer data. GLOBAL; unknown.

- Zero data retention: Retained: provider logging.
- Training: No training on customer data.
- Logging: Other
- Caching: Prompt cache
- Transfer mechanism: unknown

Verified by Opper on 2026-09-28.

### Perplexity — United States

Zero data retention: nothing is logged, held for abuse monitoring or used for training. No training on customer data. US; SCCs.

- Zero data retention: Yes. Nothing is logged, held for abuse monitoring or used for training.
- Training: No training on customer data.
- Logging: None
- Abuse monitoring: On by default, keeps nothing
- Transfer mechanism: SCCs

Verified by Opper on 2026-09-16.

## Benchmarks

Independent benchmark scores via [Artificial Analysis](https://artificialanalysis.ai) ([view on AA](https://artificialanalysis.ai/models/sonar)). Indices and domain scores are out of 100, Omniscience runs from −100 to 100, Briefcase is an Elo rating, and the other evaluation scores are the share of tasks solved.

- Global rank: #315 of 523 LLMs on the [LLM leaderboard](https://opper.ai/llm-leaderboard)
- Tier: Efficient
- Intelligence Index (previous version): 8.7

### Coding

- LiveCodeBench: 30%

### Science & reasoning

- Humanity's Last Exam: 5%
- GPQA Diamond: 62%

### Knowledge

- MMLU-Pro: 69%

## Get started

Call Perplexity Sonar through the Opper gateway with one API key. Opper is drop-in compatible with the OpenAI, Anthropic and Google AI SDKs.

Perplexity Sonar is a premium model on Opper. Sign up needs no credit card: you get an API key straight away and the free models work in the playground and the API. Add a card to use premium models, pay-as-you-go with no minimum.

### Set it up with your agent

Paste this into a coding agent like Claude Code, Cursor or Codex and it will wire up Opper for you:

```text
Use curl to download, read and follow: https://skills.opper.ai Call Perplexity Sonar
```

### Or call it directly

OpenAI:

```javascript
import OpenAI from "openai";

const client = new OpenAI({
  apiKey: process.env.OPPER_API_KEY,
  baseURL: "https://api.opper.ai/v3/compat",
});

const completion = await client.chat.completions.create({
  model: "perplexity-agent/sonar",
  messages: [{ role: "user", content: "Hello" }],
});
console.log(completion.choices[0].message.content);
```

Anthropic:

```javascript
import Anthropic from "@anthropic-ai/sdk";

const client = new Anthropic({
  apiKey: process.env.OPPER_API_KEY,
  baseURL: "https://api.opper.ai/v3/compat",
});

const message = await client.messages.create({
  model: "perplexity-agent/sonar",
  max_tokens: 1024,
  messages: [{ role: "user", content: "Hello" }],
});
console.log(message.content);
```

Gemini:

```javascript
import { GoogleGenAI } from "@google/genai";

const ai = new GoogleGenAI({
  apiKey: process.env.OPPER_API_KEY,
  httpOptions: { baseUrl: "https://api.opper.ai/v3/compat" },
});

const response = await ai.models.generateContent({
  model: "perplexity-agent/sonar",
  contents: "Hello",
});
console.log(response.text);
```

cURL:

```bash
curl https://api.opper.ai/v3/compat/chat/completions \
  -H "Authorization: Bearer $OPPER_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "perplexity-agent/sonar",
    "messages": [{ "role": "user", "content": "Hello" }]
  }'
```

## Use Perplexity Sonar in your apps

Pick your tool to see how to run it on Perplexity Sonar through Opper.

- [Claude Code](https://opper.ai/apps/claude-code/sonar)
- [Claude Cowork](https://opper.ai/apps/claude-cowork/sonar)
- [Codex](https://opper.ai/apps/codex/sonar)
- [DeepSeek Harness](https://opper.ai/apps/deepseek-harness/sonar)
- [GitHub Copilot CLI](https://opper.ai/apps/github-copilot-cli/sonar)
- [Aider](https://opper.ai/apps/aider/sonar)
- [Goose](https://opper.ai/apps/goose/sonar)
- [Droid](https://opper.ai/apps/droid/sonar)
- [OpenCode](https://opper.ai/apps/opencode/sonar)
- [Pi](https://opper.ai/apps/pi/sonar)
- [OpenClaw](https://opper.ai/apps/openclaw/sonar)
- [Hermes](https://opper.ai/apps/hermes/sonar)
- [Copilot for Obsidian](https://opper.ai/apps/obsidian-copilot/sonar)
- [OmniRoute](https://opper.ai/apps/omniroute/sonar)
- [Cursor](https://opper.ai/apps/cursor/sonar)
- [Cline](https://opper.ai/apps/cline/sonar)
- [Continue](https://opper.ai/apps/continue/sonar)
- [Kilo Code](https://opper.ai/apps/kilo-code/sonar)
- [GitHub Copilot](https://opper.ai/apps/github-copilot/sonar)
- [Zed](https://opper.ai/apps/zed/sonar)
- [JetBrains AI Assistant](https://opper.ai/apps/jetbrains-ai-assistant/sonar)
- [Voidleap Code](https://opper.ai/apps/voidleap-code/sonar)
- [n8n](https://opper.ai/apps/n8n/sonar)
- [LibreChat](https://opper.ai/apps/librechat/sonar)
- [Open WebUI](https://opper.ai/apps/open-webui/sonar)
- [See all apps](https://opper.ai/apps)

## Other models from Perplexity

- [Perplexity Sonar Reasoning Pro](https://opper.ai/perplexity/sonar-reasoning-pro)
- [Perplexity Sonar Pro](https://opper.ai/perplexity/sonar-pro)
- [Perplexity Decider 1.2](https://opper.ai/perplexity/pplx-decider-v1-2)
- [Perplexity Decider Flash 1.2](https://opper.ai/perplexity/pplx-decider-flash-v1-2)
- [Perplexity Sonar Deep Research](https://opper.ai/perplexity/sonar-deep-research)
