Search
The search endpoint lets you search the web and extract contents from the results.
Get your Exa API key
Authorizations
Pass your Exa API key in the x-api-key header. You can also authenticate with Authorization: Bearer .
Body
The query string for the search.
1List of domains or domain paths to include in the search. Each entry can be a hostname (for example, example.com), a hostname with a path prefix (for example, example.com/docs), or a wildcard subdomain (for example, *.example.com). If specified, results will only come from the matching domains or paths. Use this parameter for domain or path filtering instead of adding a site: operator to the query.
1200List of domains or domain paths to exclude from search results. Each entry can be a hostname (for example, example.com), a hostname with a path prefix (for example, example.com/docs), or a wildcard subdomain (for example, *.example.com). If specified, no results will be returned from the matching domains or paths. Use this parameter for domain or path filtering instead of adding a site: operator to the query.
1200Only links with a published date after this will be returned. Must be specified in ISO 8601 format.
Only links with a published date before this will be returned. Must be specified in ISO 8601 format.
Number of results to return. Limits vary by search type. The maximum public limit is 100 results. Contact sales (hello@exa.ai) to discuss higher limits.
1 <= x <= 100Enable content moderation to filter unsafe content from search results.
Content options for text, highlights, summary, extras, and freshness controls.
Additional query variations for deep-search variants. Only works with a deep-search type. When provided, these queries are used alongside the main query for broader results.
1 - 10 elementsThe search mode to use. Defaults to auto, a balanced mode recommended for most applications.
auto: The default. A balanced mode that optimizes for both quality and speed and is recommended for most applications.lite: Low-cost, low-latency search for real-time and interactive experiences such as chat, voice agents, and autocomplete. Accepts onlyquery(a single string),objective,userIdentifier,metadata,category,numResults,contents.highlights,contents.text,contents.snapshotAsOf,userLocation,includeDomains,excludeDomains,startPublishedDate,endPublishedDate,moderation, andcompliance; a request that sets any other parameter is rejected. Serves cached content only; it never fetches live, so the freshness options are rejected.deep-lite: Performs lightweight research with synthesized results and a consistent 4-second latency, lower than full deep search.deep: Conducts comprehensive multi-step research with synthesis.instant: Legacy. Useliteinstead. Runs a minimum-latency search that trades some search depth for speed. Unlikelite, it accepts every search parameter.fast: Legacy. Useliteinstead. Runs a reduced-latency search for user-facing and interactive workflows. Unlikelite, it accepts every search parameter.deep-reasoning: Legacy. Usedeepinstead. Runsdeepwith stronger reasoning at each step, for complex analysis and decision-making tasks. For agentic, multi-step research, use the Agent API.
"auto"A data category to focus on. Other strings are accepted and used as category hints. people and company return higher-quality people profiles and company pages. publication returns scholarly publications such as research papers, preprints, and journal articles, with metadata like authors, venue, and citations. company and people do not support startPublishedDate or endPublishedDate, and people also does not support excludeDomains. Requests that set an unsupported filter return a 400 error.
company, publication, news, personal site, financial report, people The end user's location, as a two-letter ISO 3166-1 country code (e.g. US) or an object with country, a latitude and longitude pair, or both. The country localizes results. Coordinates are used only for queries that name no place but depend on where the user is, such as "coffee near me". They do not set a country, so send country with them to localize results. Send only the precision your use case needs.
Enterprise-only compliance mode. Set to hipaa for HIPAA mode. Requires cache-only retrieval with supported parameters. See the HIPAA docs for details.
hipaa JSON schema for synthesized output. Supported root types are "text" and "object". When provided, the response includes an output object whose content matches this schema. Works with every search type and adds about 2 seconds of synthesis latency on top of the selected search type. Object schemas are limited to 10 properties in total (nested and array items properties count toward the limit) and 2 levels of nesting, and every array must define items.
- Option 1
- Option 2
The broader goal this search serves: the task the caller is working on, beyond the query itself. When exposing this field to an agent as a tool parameter, describe it as: "Goal for this search turn; say which documents should rank first, which should be excluded, and what specific facts or figures to pull from them."
4096An opaque ID your platform assigns to the end user this request is made for, such as a UUID. Lets Exa attribute usage to that end user rather than your whole team. Must not contain personal information such as an email address, phone number, username, or name. Hash such values before sending them. 1 to 64 characters: letters, digits, underscores, and hyphens. Retained even when your team has Zero Data Retention enabled. Does not affect results.
1 - 64^[A-Za-z0-9_-]+$"7f3a9c52-1d4e-4b8a-9e60-2c5d8a1f0b37"
Additional instructions that guide generated output or agent behavior. Use this for source preferences, novelty constraints, duplication constraints, or other behavior guidance.
Requests server-sent events for synthesized output streaming. Streaming is currently used only when outputSchema is provided; otherwise the endpoint returns the normal JSON search response.
Deprecated. Ignored by the API. Setting it adds an IGNORED_FIELD warning to the response's warnings.
Deprecated. Ignored by the API. Setting it adds an IGNORED_FIELD warning to the response's warnings.
Deprecated. List of strings that must be present in the webpage text of results. Matching is approximate (word-level rather than exact phrase), so a multi-word entry can match pages where its words appear separately. Up to 50 strings, each up to 4096 characters.
504096Deprecated. List of strings that must not be present in the webpage text of results. Matching is approximate (word-level rather than exact phrase). Up to 50 strings, each up to 4096 characters.
504096Deprecated. Use highlights or text instead. Returns page contents as a combined context string.
Response
OK
- Option 1
- Option 2
A list of search results containing title, URL, published date, and author.
Synthesized output. Returned when outputSchema is provided.
Unique identifier for the request.
Estimated dollar cost of the request. Which fields appear depends on the endpoint.
Server-side processing time in milliseconds. May exclude output synthesis time, so it can be lower than end-to-end latency.
Warnings about the request, such as a field that has no effect. Log them; do not pass them to a model. Omitted when there are none.
Notices about how the results were produced. Pass them to your model with the results. Omitted when there are none.
Deprecated. May be an empty string. Do not branch on this value.
Deprecated. Use results[].highlights or results[].text instead. Combined context string from search results.