Search API
Brave Search API
Brave search results as JSON from one GET request: results from Brave's own independent index: 20 organic results a page, the sponsored result, related searches, and People also ask with the answers. 10 credits a search, and a failed search costs nothing.
Quick start
curl "https://api.webfetch.io/v1/brave?search=best+running+shoes" \
-H "Authorization: Bearer wfk_your_key"JavaScript (npm install @tuxxin/webfetch)
const r = await client.brave('best running shoes');
r.organic_results[0].url;Python (pip install webfetch-io)
r = client.brave("best running shoes")
r["organic_results"][0]["url"]PHP (composer require tuxxin/webfetch)
$r = $client->brave('best running shoes');
$r['organic_results'][0]['url'];Also served at https://webfetch.io/api/v1/brave
.
The key goes in the Authorization header, or in api_key. AI agents can run the same search
with the MCP server's search_web tool.
How it works
- You send the query and the options below. The search goes out through our proxy network from the country you pick, never from our own servers.
- Every Brave search loads in a real browser: Brave answers plain fetches with a captcha. A light request skips images, fonts and media; a regular request loads the page in full.
- If Brave answers with a bot check, the search is retried on another exit, up to three times within 90 seconds, and the exit that was blocked rests for a while.
- The page is read into JSON in a fixed shape: every key is present on every response, lists are ranked from position 1, and result links are the destination pages.
- A results page is billed, including one with no results. Anything else is not.
Parameters
| Parameter | Default | What it does |
|---|---|---|
search | required | The query, as typed in the search box. Operators such as site: work. |
country_code | us | Two-letter country to search from. |
page | 1 | Results page, 1 to 50. 20 results a page. |
light_request | true | 10 credits when true, 15 when false. |
search_type | classic | classic for the full results page, ads for the ads only. |
add_html | false | Also return the page's HTML, in html. |
tag | none | Your own label, echoed back in Wf-Tag. |
Response
A real Brave search for "best running shoes" from US, first results only. Empty lists are always present, so a client never checks whether a key exists.
{
"meta_data": {
"url": "https://search.brave.com/search?q=best%20running%20shoes&source=web",
"number_of_results": null,
"location": null,
"number_of_organic_results": 20,
"number_of_ads": 1,
"number_of_page": 1,
"zero_results_for_original_query": false
},
"organic_results": [
{
"position": 1,
"title": "7 Best Running Shoes in 2026 | RunRepeat",
"url": "https://runrepeat.com/guides/best-running-shoes",
"displayed_url": "runrepeat.com \u203a running shoes \u203a best running shoes",
"description": "The 7 best running shoes based on extensive wear and lab testing. We award the best overall, best daily trainer, best for tempo, best for race, best shock absorption, best energy return and best stability.",
"domain": "runrepeat.com",
"date": "September 13, 2026",
"date_utc": null,
"rich_snippet": [],
"sitelinks": []
},
{
"position": 2,
"title": "The 15 Best Running Shoes of 2026, Tested by Runner\u2019s World",
"url": "https://www.runnersworld.com/gear/a19663621/best-running-shoes/",
"displayed_url": "runnersworld.com \u203a running gear \u203a running shoes \u203a the 15 best running shoes of 2026",
"description": "Best Daily Trainer for Wide Feet: Brooks Glycerin 23 (Men\u2019s/Women\u2019s) For Runners Logging Long Runs: Nike Structure Plus (Men\u2019s/Women\u2019s) At Runner\u2019s World, we\u2019ve tested gear since 1966.",
"domain": "www.runnersworld.com",
"date": "August 3, 2026",
"date_utc": null,
"rich_snippet": [],
"sitelinks": []
}
],
"top_ads": [
{
"position": 1,
"title": "Amazon.com: Running Shoes",
"url": "https://www.amazon.com/running-shoes/s?k=running%20shoes&tag=ustxtaddt-20",
"tracking_url": "https://search.brave.com/a/redirect?click_url=https%3A%2F%2Fwww.amazon.com%2Frunning-shoes%2Fs%3Fk%3Drunning%2520shoes%26tag%3Dustxtaddt-20&placement_id=43d94e70-87f8-4380-a0ec-0ce90131faca&creative_instance_id=483a49a6-479f-4387-86a3-29a1276ef9b0×tamp=1792474358&c_idx=-1&ad_type_display=simple&ad_display_context=search&nonce=6865450f67982d9b10b0faea47129126&sig=f70ff30045b78b8c7604d68812eea4eb3d99ba1f621dc5eee707a45fe17611a1",
"visual_url": "amazon.com \u203a running-shoes \u203a s",
"domain": "amazon.com",
"description": "Find running shoes built for every runner. From neutral support to trail-ready options, di...",
"snippet": null,
"sitelinks": []
}
],
"bottom_ads": [],
"related_queries": [
{
"position": 1,
"title": "best running shoes long distance",
"url": "https://search.brave.com/search?q=best%20running%20shoes%20long%20distance&source=relatedQueries"
},
{
"position": 2,
"title": "best running shoes men",
"url": "https://search.brave.com/search?q=best%20running%20shoes%20men&source=relatedQueries"
}
],
"related_searches": [
{
"position": 1,
"query": "best running shoes long distance",
"link": "https://search.brave.com/search?q=best%20running%20shoes%20long%20distance&source=relatedQueries",
"type": "standard"
},
{
"position": 2,
"query": "best running shoes men",
"link": "https://search.brave.com/search?q=best%20running%20shoes%20men&source=relatedQueries",
"type": "standard"
}
],
"questions": [],
"knowledge_graph": [],
"local_results": [],
"top_stories": [],
"news_results": [],
"images": [],
"map_results": [],
"hotel_results": [],
"ai_overviews": []
}Ads only
With search_type=ads the response has the same keys, with the ads filled in and the other lists empty.
Each ad has its position, its landing page in url, and Brave's click URL in
tracking_url. A page with no ads returns empty lists. Same price as a full search.
{
"meta_data": {
"url": "https://search.brave.com/search?q=car%20insurance%20quotes&source=web",
"number_of_results": null,
"location": null,
"number_of_organic_results": 0,
"number_of_ads": 1,
"number_of_page": 1,
"zero_results_for_original_query": false
},
"organic_results": [],
"top_ads": [
{
"position": 1,
"title": "Best Extended Warranty 2026 | Our Top Picks for 2026",
"url": "https://www.top10.com/car-warranty/comparison?utm_source=brave&utm_campaign=048f0de5-171d-41a9-88bf-2675ad671bf4&groupid=b6236d00-82e7-4a7a-aa5d-8784e14bca14&c=d620601c-8731-4ba9-a255-21b2bf9ae035&campaignid=048f0de5-171d-41a9-88bf-2675ad671bf4&customizer.year=2026",
"tracking_url": "https://search.brave.com/a/redirect?click_url=https%3A%2F%2Fwww.top10.com%2Fcar-warranty%2Fcomparison%3Futm_source%3Dbrave%26utm_campaign%3D048f0de5-171d-41a9-88bf-2675ad671bf4%26groupid%3Db6236d00-82e7-4a7a-aa5d-8784e14bca14%26c%3Dd620601c-8731-4ba9-a255-21b2bf9ae035%26campaignid%3D048f0de5-171d-41a9-88bf-2675ad671bf4%26customizer.year%3D2026&placement_id=77e864bd-c663-42c6-814b-d2274b9e31a4&creative_instance_id=d620601c-8731-4ba9-a255-21b2bf9ae035×tamp=1792474462&c_idx=-1&ad_type_display=simple&ad_display_context=search&nonce=09099d63b3e8e5385974f5c585018869&sig=528228c44cb318216b10ac90a57eb3546f623cd422e992fbdd26a4a1bd733018",
"visual_url": "top10.com \u203a car-warranty \u203a comparison",
"domain": "top10.com",
"description": "Business identity verified\u201aCompare the Best Extended Car Warranty and Pick the Plan That's Best for Your Vehicle!",
"snippet": null,
"sitelinks": []
}
],
"bottom_ads": []
}Questions
Is it compatible with ScrapingBee?
ScrapingBee has no Brave endpoint. This one takes the parameters of their Google Search API and returns the same response shape, so code written for one works for the other.
What does a search cost?
10 credits for a light request (the default) and 15 for a regular one. An ads-only search costs the same. Credits come from your plan's monthly allowance, or from the free credit balance.
Do failed searches cost credits?
No. A search Brave blocks, one that times out, or one that returns a page that is not a results page is never billed. A blocked search is retried on another exit first, up to three times.
Which countries can I search from?
19 right now: United States, Argentina, Australia, Brazil, Canada, China, Colombia, Germany, India, Indonesia, Italy, Japan, Mexico, Saudi Arabia, South Africa, South Korea, Spain, Turkey, United Kingdom. Set country_code; a country we cannot search from is refused rather than answered from somewhere else.
Why does it need the robots.txt opt-out?
Brave's robots.txt disallows automated access to its result pages, and webfetch honors robots.txt unless you turn the opt-out on in your key portal. Turning it on records your acceptance of the acceptable use policy. Paid plans turn it on themselves; free accounts request it in the key portal, and a person approves each request.
More
- Google Search API
- Bing Search API
- Yahoo Search API
- Search API overview
- Brave search tool, with JSON and CSV export
- Search API reference: errors, headers and every option
- Pricing and how webfetch compares with ScrapingBee