Brave Search

Web search and content extraction via Brave Search API. Use for searching documentation, facts

Brave Search is a community skill for privacy-focused web search, covering independent index queries, AI-summarized results, location-aware search, news filtering, and API integration for building search into AI agent workflows.

What Is This?

Overview

Brave Search provides AI agents with access to Brave's independent web search index that does not rely on Google or Bing for its results. It covers independent index queries that return results from Brave's own web crawler rather than third-party search providers, AI-summarized results that provide concise answer snippets alongside traditional link listings for faster information consumption, location-aware search that adjusts results based on geographic context for local business and event queries, news filtering that separates current news articles from general web results for topic monitoring, and API integration that provides structured JSON responses suitable for programmatic consumption by AI agents and automation tools. The skill enables privacy-conscious search without tracking or profiling user query patterns.

Who Should Use This

This skill serves AI agent developers wanting an alternative to Google-based search results, privacy-focused applications requiring trackingless search, and developers building research tools that benefit from diverse search index coverage.

Why Use It?

Problems It Solves

Most search APIs rely on Google or Bing indexes, providing similar results and limiting result diversity for research tasks. Mainstream search providers track query patterns and build user profiles that raise privacy concerns for sensitive research topics. Search result quality varies by provider, and having access to an independent index provides different perspectives on the same query. Free search API tiers often have very low rate limits that restrict usage in production AI agent workflows.

Core Highlights

Independent crawler returns results from Brave's own index rather than third-party providers. AI summarizer generates concise answer snippets from search results. Location filter adjusts results for geographic relevance in local queries. News separator isolates current news articles from general web page results.

How to Use It?

Basic Usage

import os, requests

api_key = os.environ[
    'BRAVE_API_KEY']

resp = requests.get(
    'https://api.search'
    '.brave.com/res/v1'
    '/web/search',
    headers={
        'X-Subscription'
        '-Token': api_key},
    params={
        'q': 'rust async'
             ' runtime',
        'count': 10})

for r in resp.json()[
        'web']['results']:
    print(f'{r["title"]}')
    print(f'{r["url"]}\n')

Real-World Examples

news = requests.get(
    'https://api.search'
    '.brave.com/res/v1'
    '/news/search',
    headers={
        'X-Subscription'
        '-Token': api_key},
    params={
        'q': 'tech layoffs',
        'count': 5,
        'freshness': 'pw'})

for article in news\
        .json()['results']:
    print(
        f'{article["title"]}'
        f' | {article["age"]}')

summary = requests.get(
    'https://api.search'
    '.brave.com/res/v1'
    '/web/search',
    headers={
        'X-Subscription'
        '-Token': api_key},
    params={
        'q': 'what is WebGPU',
        'summary': 1})

data = summary.json()
if 'summarizer' in data:
    print(data[
        'summarizer'][
        'key'])

Advanced Tips

Use the freshness parameter with values like pd (past day) or pw (past week) to restrict results to recent content for time-sensitive queries. Enable the summary endpoint to get AI-generated answer snippets alongside traditional search results for quick answers. Combine web and news search endpoints to get comprehensive coverage of both evergreen content and current events.

When to Use It?

Use Cases

Build a privacy-respecting research assistant that searches the web without query tracking. Add an independent search source to a multi-engine search aggregator for broader result diversity. Monitor news topics with the news search endpoint for automated media tracking workflows.

Related Topics

Web search APIs, privacy-focused search, independent search indexes, news monitoring, AI summarization, and search engine diversity.

Important Notes

Requirements

A Brave Search API key obtained from the Brave developer portal for authentication. Python with the requests library for making HTTP calls to search endpoints. Network access to the Brave Search API servers for query execution.

Usage Recommendations

Do: use the freshness parameter for time-sensitive queries to filter out outdated results. Leverage the news endpoint separately when specifically looking for current events coverage. Cache search results when making repeated queries for the same terms within short time windows.

Don't: assume Brave Search covers all the same pages as Google since independent indexes have different crawl coverage. Exceed API rate limits by sending too many parallel requests without implementing proper throttling. Use the summary feature as a sole source of truth since AI-generated summaries may miss nuances.

Limitations

Brave's independent index may have smaller coverage than Google for niche or specialized topics. The AI summary feature is available only on certain subscription tiers and may not be included in free plans. Search result freshness for rapidly changing topics depends on Brave's crawl frequency for those domains.