DuckDuckGo API: Search the web
Searches the web privately with DuckDuckGo in a chosen region and returns the ordered organic results without ads, plus DuckDuckGo's instant answer when it shows one.
Unofficial. Not affiliated with or endorsed by DuckDuckGo.
Inputs
Values from the run on Oct 31, 2026, shown under Output.
- Query, required
query Search words, for example how to file a trademark.
python programming language
- Region optional
region Country name or two-letter country code, for example United States or DE.
United Kingdom
Default
United States.- Max Results optional
max_results Maximum number of organic results to return, for example 20.
24
Whole number from 1 to 50. Default
10.
Input as JSON
{ "query": "python programming language", "region": "United Kingdom", "max_results": 24}Output
{ "results": [ { "link": "https://www.python.org/" , "snippet": "Python is a versatile and easy-to-learn language that lets you work quickly and integrate systems more effectively. Learn more about Python , download the latest version, access documentation, find jobs, events, success stories and more.", "position": 1, "page_title": "Welcome to Python.org", "website_name": "python.org" }, { "link": "https://en.wikipedia.org/wiki/Python_(programming_language)" , "snippet": "Python supports multiple programming paradigms but with an emphasis on object-oriented programming and dynamic typing. Guido van Rossum began working on Python in the late 1980s as a successor to the ABC programming language . Python 3.0, released in 2008, was a major revision and not completely bac…", "position": 2, "page_title": "Python (programming language) - Wikipedia", "website_name": "en.wikipedia.org" }, { "link": "https://www.python.org/downloads/" , "snippet": "The official home of the Python Programming Language", "position": 3, "page_title": "Download Python | Python.org", "website_name": "python.org" } ], "instant_answer": "Python is a high-level, general-purpose programming language that emphasizes code readability, simplicity, and ease-of-writing with the use of significant indentation, an extensive standard library, and garbage collection. Python supports multiple programming paradigms but with an emphasis on object…"}Code
curl https://api.fous.com/v1/runs \ -H "Authorization: Bearer $FOUS_API_KEY" \ -H "Content-Type: application/json" \ -d '{"method":"duckduckgo.com/search_web","input":{"query":"python programming language","region":"United Kingdom","max_results":24}}' # Save as fous.py, then run: python3 fous.pyimport json, os, timefrom urllib.error import HTTPErrorfrom urllib.request import Request, urlopenAPI = "https://api.fous.com/v1/runs" KEY = os.environ["FOUS_API_KEY"]HEADERS = { "Authorization": f"Bearer {KEY}", "Content-Type": "application/json" ,}def call(url, body=None): data = json.dumps(body).encode() if body else None request = Request(url, data, HEADERS) try: with urlopen(request, timeout=120) as r: return r.status, json.load(r) except HTTPError as error: message = json.load(error)["error"]["message"] raise RuntimeError(message) from errorstatus, run = call(API, { "method": "duckduckgo.com/search_web" , "input": { "query": "python programming language", "region": "United Kingdom", "max_results": 24 }})# 202: still going after 30 s. Ask again until it ends.while status == 202: time.sleep(2) status, run = call(f"{API}/{run['id']}")print(json.dumps(run["data"], indent=2))// Save as fous.mjs, then run: node fous.mjsconst api = "https://api.fous.com/v1/runs" ;const headers = { Authorization: `Bearer ${process.env.FOUS_API_KEY}`, "Content-Type": "application/json" ,};let response = await fetch(api, { method: "POST", headers, body: JSON.stringify({ "method": "duckduckgo.com/search_web" , "input": { "query": "python programming language", "region": "United Kingdom", "max_results": 24 } }), signal: AbortSignal.timeout(120_000),});let run = await response.json();// 202: still going after 30 s. Ask again until it ends.while (response.status === 202) { await new Promise((done) => setTimeout(done, 2_000)); response = await fetch(`${api}/${run.id}`, { headers }); run = await response.json();}if (!response.ok) throw new Error(run.error.message);console.log(run.data);# Connect your agent to Fous once, over MCP (Streamable HTTP):# https://api.fous.com/mcp# Set FOUS_API_KEY first: create a key at https://app.fous.com/keys.# Claude Codeclaude mcp add \ --scope user \ --transport http fous https://api.fous.com/mcp \ --header "Authorization: Bearer ${FOUS_API_KEY:?Set FOUS_API_KEY to your Fous API key}"# Codexcodex mcp add fous \ --url https://api.fous.com/mcp \ --bearer-token-env-var FOUS_API_KEY# Cursor, VS Code, Windsurf, Cline and morenpx -y add-mcp https://api.fous.com/mcp -g -n fous \ --header "Authorization: Bearer ${FOUS_API_KEY:?Set FOUS_API_KEY to your Fous API key}"# Then ask your agent:# "Use Fous to run duckduckgo.com/search_web# with {"query":"python programming language","region":"United Kingdom","max_results":24}"Over HTTP, the answer’s data holds the output. A run still going after 30 seconds answers 202 with its id: ask GET /v1/runs/{id} until it ends.
Schema
Input schema
{ "type": "object", "required": [ "query" ], "properties": { "query": { "type": "string", "minLength": 1, "description": "Search words, for example how to file a trademark." }, "region": { "type": "string", "default": "United States", "description": "Country name or two-letter country code, for example United States or DE." }, "max_results": { "type": "integer", "default": 10, "maximum": 50, "minimum": 1, "description": "Maximum number of organic results to return, for example 20." } }}Output schema
{ "type": "object", "required": [ "results", "instant_answer" ], "properties": { "results": { "type": "array", "items": { "type": "object", "required": [ "position", "page_title", "website_name", "link", "snippet" ], "properties": { "link": { "type": "string" }, "snippet": { "type": "string" }, "position": { "type": "integer" }, "page_title": { "type": "string" }, "website_name": { "type": "string" } }, "additionalProperties": false }, "description": "Organic search results in displayed order." }, "instant_answer": { "type": [ "string", "null" ], "description": "DuckDuckGo instant-answer text when available." } }, "additionalProperties": false}- Price
- 1 credit per completed run (1¢ with pay as you go); failed runs are free.
- Method
duckduckgo.com/search_web- Returns
- position, page title, website name, link, snippet; instant answer
Use it from your agent
Give your agent this line. It reads SKILL.md, gets a Fous API key and connects the Fous MCP server. Its run then takes the method duckduckgo.com/search_web with the inputs above.
Ask your agent
- Search DuckDuckGo for "best budget mechanical keyboard 2024" and give me the top 15 organic results with titles, links, and snippets
- I need web results for "how to renew a German passport abroad" as seen from Germany, just the first 10 links
- Look up "symptoms of vitamin D deficiency" privately and show me any instant answer plus the top 5 results
- Find web pages about "cheap flights Toronto to Lisbon" from a Canada region search, up to 25 results, no ads
- Run a private DuckDuckGo search in the UK for "council tax bands explained" and list the ranked results with site names
See more
Searches Bing and returns web results in the order shown, with snippets, answer-box text when available, and related searches.
bing.com/search_webGets Google Search autocomplete suggestions for words typed so far, in Google's order, for a chosen country and language.
google.com/get_search_suggestionsShows where a search term has the highest relative Google Trends interest, by country worldwide or by region within a country. Scores run from 0 to 100.
trends.google.com/get_interest_by_regionFinds iPhone and iPad apps by keyword in a chosen country's App Store, with ratings, prices, categories and App Store links.
apps.apple.com/search_appsFinds Chrome Web Store extensions by keywords in store order, with each listing's developer, users, rating, rating count, short description and store link. Some listings omit developer, users or ratings.
chromewebstore.google.com/search_extensionsSearches Amazon products in a chosen country store, with price range, sort, Prime and page options. Returns the listings and prices shown to an anonymous shopper in the store's currency.
amazon.com/search_productsFinds Android apps on Google Play by keywords, in Play search order, with each listing's developer, star rating, price and currency for the chosen country, download range and link. Results are limited to apps shown on the public search page.
play.google.com/search_appsFinds DoorDash restaurants delivering to a street address or ZIP code, optionally for a cuisine or dish, in DoorDash's search order. Fees and times reflect guest offers; the numeric fee is null when DoorDash shows no amount.
doordash.com/search_restaurants