--- id: serpapi version: "1.1.0" license: MIT license_treatment: permissive maintenance: active --- # serpapi — The official Python client for SerpApi.com. License: permissive · Maintenance: active · Downloads: 576.0K/mo ## What it is and what it does serpapi is the official Python wrapper for SerpApi.com, a search engine aggregation service. It lets you query results from Google, Bing, Baidu, Yahoo, eBay, YouTube, Walmart, DuckDuckGo, Naver, and other engines through a unified client interface, returning structured JSON-like results. The package handles authentication via API key, timeouts, and error cases (HTTPError for bad requests or auth failures, TimeoutError for slow responses). You instantiate a Client with your API key, call search() with an engine name and query parameters, and get back a SerpResults object that behaves like a dictionary. The package is designed for integration into AI workflows, RAG pipelines, fine-tuning datasets, and data mining at scale. It depends only on requests for HTTP transport. Use it for: - Fetch Google search results programmatically for web scraping or data collection pipelines. - Query e-commerce platforms (eBay, Walmart) for product listings and pricing data at scale. - Integrate search results into machine learning training datasets or RAG (retrieval-augmented generation) systems. - Build multi-engine search aggregators that query Bing, Baidu, or Yahoo in a single codebase. - Retrieve structured data like news headlines, stock market data, or flight schedules via SerpApi's supported engines. ## Worth the install? AI-flagged interpretation of the facts above — verify before relying. Official Python client for SerpApi that queries multiple search engines and data sources (Google, Bing, Baidu, Yahoo, eBay, YouTube, and others) and returns structured results as dictionary-like objects. Yes. The package is actively maintained, has low install friction, carries a permissive MIT license, and provides a clean, documented interface to a large set of search engines. Install it if you need programmatic access to search results or structured data from multiple sources. The main gotcha is that it requires a SerpApi account and API key, so verify pricing and rate limits for your use case before committing. ## Install pip install serpapi uv add serpapi poetry add serpapi ## Installing serpapi Before you install: Low install friction with a single dependency (requests) and a pure-wheel distribution. The package is actively maintained with a recent release and 166 repository stars, supporting Python 3.6 through 3.14. License in practice: MIT license is permissive and places no restrictions on use, modification, or redistribution in commercial or private projects. Quickstart: import os import serpapi client = serpapi.Client(api_key=os.getenv("SERPAPI_KEY")) results = client.search({ "engine": "google", "q": "coffee" }) print(results) Requires a valid SerpApi API key (obtainable from serpapi.com/users/sign_up) and network access to SerpApi's backend service. Verify before relying: - Whether the SerpApi service itself requires a paid subscription or if free tier access is available for all supported engines - Rate limiting or throughput constraints imposed by the SerpApi backend service ## Package facts - License: MIT (permissive) - Python support: supports_current - Install friction: low - Maintenance: active - Downloads: 576.0K/month (top 15,000 on PyPI) - Known vulnerabilities: none known ## Tags search engine api wrapper, google search results python, multi-engine search scraping, serp results client, web search data integration, search api aggregator, structured search results, search-api, web-scraping, data-aggregation [View on SkillFed](https://skillfed.io/packages/serpapi) · [View on PyPI](https://pypi.org/project/serpapi/)