Perplexity is no longer just one search-grounded model API. Its developer platform now spans Agent API, Gateway API, Search API, Embeddings API, and the legacy Sonar Chat Completions surface.

That distinction matters because each product has a different billing unit. The live modules above cover the tracked Sonar token component. They do not represent the full cost of every Perplexity product or every Sonar request. Use the Perplexity pricing page for the tracked model catalog and the AI token calculator to test your own input-to-output mix.

Which Perplexity API Should You Use?

WorkloadStart withMain billing driversMeasure
Grounded agent with search and toolsAgent APIModel tokens, tool calls, and optional sandbox useCost per accepted task
Multi-provider model accessGateway APISelected model tokensReliability and total token cost
Raw web results for your own pipelineSearch APISearch requestsUseful results per query
Existing cited-answer integrationSonar APITokens plus request or research-specific usageCost per grounded answer
Retrieval over private contentEmbeddings APIEmbedded tokens and vector infrastructureRecall per indexed dollar

Use Agent API when one request should combine a model, web grounding, tools, and an agent loop. Perplexity documents model access from multiple providers, built-in search and fetch tools, reasoning controls, token budgets, structured output, and an OpenAI-compatible endpoint.

Use Gateway API when the main value is one key and one interface for frontier models. Perplexity says Gateway model tokens carry no markup, but your bill still depends on the selected provider model, output length, caching eligibility, and fallback behavior.

Use Search API when you need ranked web results rather than a generated answer. It is usually the cleaner primitive for an application that already has its own model, reranker, citation layer, or deterministic presentation logic.

How Agent API and Gateway Billing Work

Agent API combines several meters in one run. Model input, cached input where supported, and output are charged separately. Built-in tools such as web search, URL fetch, people search, and finance search are priced per invocation. Sandbox sessions and sandbox searches have their own meters.

This makes cost per run more useful than token price alone. A cheap model can still produce an expensive job if it loops, calls search repeatedly, opens many pages, or retries a failed tool action. Read the response usage object and store its reported cost next to task outcome, latency, tool-call count, and retry count.

Perplexity also offers presets that package models and tools for common workloads. Presets shorten setup, but their example usage is not a guaranteed bill. Treat the official pricing calculator as an estimate and the metered response as the source for each completed run.

Gateway is simpler: choose a model, send an OpenAI Chat Completions- or Anthropic Messages-compatible request, and pay the model’s token rates. Test compatibility details such as tool schemas, streaming events, reasoning fields, and cached-token reporting before replacing a direct provider endpoint.

The official Agent API documentation and Gateway catalog are the current sources for availability and billing behavior.

How Legacy Sonar Pricing Works

The live table above shows the token component for Sonar, Sonar Pro, Sonar Reasoning Pro, and Sonar Deep Research from pricing.json. It is not the whole invoice.

Standard Sonar variants also add a request charge based on the selected search-context size. Deep Research uses a different structure that can include input, output, citation, and reasoning tokens plus search-query usage. Pro Search is another Sonar Pro mode and should not be estimated as an ordinary request without checking its current billing rules.

Perplexity’s current pricing documentation labels Sonar Chat Completions as legacy and points new development toward Agent API. Existing users should read the Sonar-to-Agent migration guide, replay a representative request set, and compare grounded-answer quality and total metered cost before switching.

Do not compare Sonar’s token line with a bare language-model call. Sonar bundles web retrieval and citations; the fair comparison includes the search API, ranking, source filtering, retry logic, and citation work your alternative stack requires.

Hidden Costs and Cost Controls

Tool loops can dominate the bill. Set maximum tool calls and loop depth. A broad research instruction can fan out into many searches and page fetches.

Search context is a cost setting. Use the smallest search context that meets recall and citation-quality requirements. Measure whether a larger context changes accepted-answer rate enough to justify the added request charge.

Output and reasoning need caps. Ask for structured, compact results when long prose is not valuable. Track hidden reasoning usage where the selected model exposes it.

Fallbacks trade cost for availability. A Gateway or Agent fallback may rescue a request with a more expensive model. Log which model actually served each response and set a budget ceiling for automatic escalation.

Subscriptions are separate. Perplexity Free, Pro, and Max are consumer products; do not treat a seat as prepaid production API usage. Compare those plans on the Perplexity subscription pricing page.

Retrieval has downstream costs. Embeddings pricing covers model usage, not vector storage, indexing, document updates, reranking, or application hosting.

Perplexity vs Building Your Own Search Stack

Perplexity is strongest when grounded search, citations, managed tools, or multi-provider routing remove infrastructure your team would otherwise build. OpenAI pricing is a useful direct-model baseline, while Google AI pricing belongs in evaluations that combine search, multimodal input, and long context.

For a consumer and API decision together, read Perplexity vs ChatGPT pricing. For a wider developer shortlist, use the AI API pricing comparison.

If fresh web grounding is not required, benchmark a lower-cost open-model route as well. Novita’s managed model catalog is one option for classification, extraction, summarization, and other tasks that can run without live search.

Affiliate disclosure: we may earn a commission if you use the Novita link above, at no extra cost to you. Compensation does not affect our pricing data or recommendations.

FAQ

Is Perplexity Agent API replacing Sonar API?

Perplexity now labels Sonar Chat Completions as legacy and directs developers to Agent API plus a migration guide. Existing Sonar integrations can continue to evaluate their current route, but new builds should compare Agent API first.

Does Perplexity charge only for tokens?

No. Depending on the product, a bill can include model tokens, tool invocations, search requests, sandbox use, Sonar request fees, citation tokens, reasoning tokens, or research search queries.

Is Perplexity Gateway cheaper than direct model APIs?

Perplexity says Gateway uses direct provider token pricing without markup. Verify the exact model rate, cache treatment, fallback behavior, and any product-specific terms before migrating.

Which Perplexity API is best for RAG?

Use Embeddings API when you own the document corpus and retrieval index. Use Search API or Agent API when the answer needs current public-web evidence, and evaluate a hybrid route when both private and web sources matter.

Bottom Line

Choose Perplexity by product surface, not brand alone. Agent API is the primary choice for grounded tool-using workflows, Gateway is for unified model access, Search API is for raw retrieval, Embeddings API is for private-corpus retrieval, and Sonar is the legacy cited-answer route.

Model each workload with every applicable meter, then optimize for cost per accepted answer or completed task. Token rates are only one part of a Perplexity bill.