---
title: "DuckDuckGo API: ranked web results, news search as JSON"
description: "DuckDuckGo API for ranked web results, news search and maps lookups as JSON: title, link, snippet and pagination. 3 endpoints, 1 credit per call."
url: https://perceptlayer.com/apis/duckduckgo
---

[APIs](https://perceptlayer.com/apis) / [Search engines](https://perceptlayer.com/verticals/search) / DuckDuckGo

1 credit per call 3 endpoints 6 datapoints 

# DuckDuckGo API

DuckDuckGo API for ranked web results, news search and maps lookups as JSON: title, link, snippet and pagination. 3 endpoints, 1 credit per call.

[Get a free API key](https://perceptlayer.com/signup) Run it below

DuckDuckGo

GET /v1/duckduckgo/search?q=laravel+taylor+otwell&kl=us-en&start=0 

```
{
  "success": true,
  "data": {
    "search_parameters": {
      "q": "laravel taylor otwell",
      "kl": "us-en",
      "safe": true,
      "start": 0
    },
    "organic_results": [
      {
        "position": 1,
        "title": "Taylor Otwell - Founder & CEO at Laravel | LinkedIn",
        "link": "https://www.linkedin.com/in/taylorotwell",
        "snippet": "Founder &amp; CEO at Laravel · Creator of Laravel, the PHP framework that empowers developers to build scalable and elegant web applications. My journey in software development has always been ...",
        "display_url": "www.linkedin.com/in/taylorotwell",
        "favicon": "https://icons.duckduckgo.com/ip3/www.linkedin.com.ico"
      },
      {
        "position": 2,
        "title": "taylorotwell (Taylor Otwell) · GitHub",
        "link": "https://github.com/taylorotwell",
        "snippet": "Creator of @laravel. taylorotwell has 10 repositories available. Follow their code on GitHub.",
        "display_url": "github.com/taylorotwell",
        "favicon": "https://icons.duckduckgo.com/ip3/github.com.ico"
      },
      {
        "position": 3,
        "title": "Laravel - Wikipedia",
        "link": "https://en.wikipedia.org/wiki/Laravel",
        "snippet": "Laravel is a free and open-source PHP -based web framework for building web applications. [3] It was created by Taylor Otwell and intended for the development of web applications following the model-view-controller (MVC) architectural patte…",
        "display_url": "en.wikipedia.org/wiki/Laravel",
        "favicon": "https://icons.duckduckgo.com/ip3/en.wikipedia.org.ico"
      }
    ],
    "pagination": {
      "current": 1,
      "has_more": true,
      "next_start": 10,
      "next": 2
    },
    "knowledge_graph": {
      "ai_answer": {
        "answer": "**Taylor Otwell** is the creator of **Laravel**, a PHP web application framework he started in **2011** as a side project for himself. He later built **Laravel Forge** in late **2013** and became full-time on Laravel by **January 2015**."
      }
    }
  },
  "meta": {
    "duration_ms": 2169,
    "endpoint_family": "web_search"
  }
}
```

200 OK JSON X-Credits-Used: 1

Recorded from our API and shortened.

Sample data

## What one call returns

A recorded run of `search`: the fields and shapes you will get, shortened to 3 items.

| # | position integer | title string | link url | snippet string | display\_url string | favicon url |
| --- | --- | --- | --- | --- | --- | --- |
| 1 | 1 | Taylor Otwell - Founder & CEO at Laravel \| LinkedIn | https://www.linkedin.com/in/taylorotwell | Founder &amp; CEO at Laravel · Creator of Laravel, the PHP framework that empowers developers to build scalable and elegant web applications. My journey in software development has always been ... | www.linkedin.com/in/taylorotwell | https://icons.duckduckgo.com/ip3/www.linkedin.com.ico |
| 2 | 2 | taylorotwell (Taylor Otwell) · GitHub | https://github.com/taylorotwell | Creator of @laravel. taylorotwell has 10 repositories available. Follow their code on GitHub. | github.com/taylorotwell | https://icons.duckduckgo.com/ip3/github.com.ico |
| 3 | 3 | Laravel - Wikipedia | https://en.wikipedia.org/wiki/Laravel | Laravel is a free and open-source PHP -based web framework for building web applications. \[3\] It was created by Taylor Otwell and intended for the development of web applications following the model-view-controller (MVC) architectural patte… | en.wikipedia.org/wiki/Laravel | https://icons.duckduckgo.com/ip3/en.wikipedia.org.ico |

Recorded from our API · 3 items shown · 6 datapoints per item GET /v1/duckduckgo/search?q=laravel+taylor+otwell&kl=us-en&start=0

6 datapoints

### Identity

-   title string

### Contact

-   link url
-   display\_url string

### Other

-   position integer
-   snippet string
-   favicon url

Playground

## Run this API

cURL shell 

```
curl "https://api.perceptlayer.com/v1/duckduckgo/search?q=laravel+taylor+otwell&kl=us-en&start=0" \
  -H "X-API-Key: $API_KEY"
```

DuckDuckGo · 3 endpoints

## Endpoints

Every endpoint takes the same key. Open one for its parameters, the fields it returns and an example request.

| Endpoint | Required parameters | Returns | Cost |
| --- | --- | --- | --- |
| [GET `/v1/duckduckgo/maps`](https://perceptlayer.com/apis/duckduckgo/maps) | `q` +6 optional | `position` `id` `name` `address` `address_lines` `city` +20 more | 1 credit |
| [GET `/v1/duckduckgo/news`](https://perceptlayer.com/apis/duckduckgo/news) | `q` +5 optional | `position` `title` `url` `source` `excerpt` `date` +3 more | 1 credit |
| [GET `/v1/duckduckgo/search`](https://perceptlayer.com/apis/duckduckgo/search) | `q` +4 optional | `search_parameters` `organic_results` `pagination` `knowledge_graph` | 1 credit |

Overview

## About the DuckDuckGo API

## What you can get

The DuckDuckGo API returns DuckDuckGo data as JSON through 3 endpoints. Each takes a required `q` of up to 499 characters.

-   **Web search:** `search`, with `kl` (such as us-en), `df` (d, w, m or y), `safe` and `start`.
-   **News:** `news`, with `region`, `safe` (strict, moderate or off), `freshness` (hour, day, week, month or year), `date_from` and `start`.
-   **Maps:** `maps`, with `lat`, `lon`, `bbox`, `country`, `l` and `limit`.

The recorded web search returns `organic_results`, each with `position`, `title`, `link`, `snippet` and `display_url`, plus `pagination` with `has_more` and `next_start`, and a `knowledge_graph` with an `ai_answer`.

## How a call works

Send `GET /v1/duckduckgo/search?q=laravel taylor otwell&kl=us-en&start=0` with your key in the `X-API-Key` header. The recorded response's `pagination` has `next_start`, and the endpoint takes a `start`. For news on the same query, call `GET /v1/duckduckgo/news?q=...&freshness=week`. Every successful call costs 1 credit; failed calls cost nothing.

The same key also calls the Google, Bing and Brave search APIs, so you can compare engines on one query.

Search engines JSON REST MCP

### More search engines APIs

[Apple Maps](https://perceptlayer.com/apis/apple-maps) [Baidu](https://perceptlayer.com/apis/baidu) [Bing](https://perceptlayer.com/apis/bing) [Brave Search](https://perceptlayer.com/apis/brave) [Google Events](https://perceptlayer.com/apis/google-events) [Google Finance](https://perceptlayer.com/apis/google-finance) [Google Forums](https://perceptlayer.com/apis/google-forums) [Google Images](https://perceptlayer.com/apis/google-images) [Google Lens](https://perceptlayer.com/apis/google-lens) [Google Local](https://perceptlayer.com/apis/google-local) [Google Local Services](https://perceptlayer.com/apis/google-local-services) [Google Maps](https://perceptlayer.com/apis/google-maps)

Use cases

### Check where a page ranks on DuckDuckGo as well as Google

`Use the DuckDuckGo API to check where a page ranks on DuckDuckGo as well as Google` 

### Monitor news for a company or topic with \`freshness\` and \`date\_from\`

`` Use the DuckDuckGo API to monitor news for a company or topic with `freshness` and `date_from` `` 

### Run map searches for a query around a \`lat\` and \`lon\`, or within a \`bbox\`

`` Use the DuckDuckGo API to run map searches for a query around a `lat` and `lon`, or within a `bbox` `` 

### Feed an AI agent web and news results from a second search engine

`Use the DuckDuckGo API to feed an AI agent web and news results from a second search engine` 

FAQ

## Questions

**Do I need a DuckDuckGo API key?**

No DuckDuckGo key is needed. You call this DuckDuckGo API with your Perceptlayer key in the \`X-API-Key\` header, and the same key works for every API in the catalogue.

**How much does the DuckDuckGo API cost?**

Each successful call costs one credit, on every endpoint. New accounts get free credits to start, and credit packs bring the price down as you scale.

**What format are responses in?**

Every endpoint returns JSON, with no HTML parsing on your side.

**Is this the official DuckDuckGo API?**

No. Perceptlayer is an independent service and is not affiliated with DuckDuckGo. It returns DuckDuckGo data as JSON with a Perceptlayer key, so there is no DuckDuckGo developer account, app review or partner approval to get first. It only reads data: if DuckDuckGo has an official API and you need to act on your own DuckDuckGo account, such as posting, managing orders or reading private data, use that one.

**Should I build a DuckDuckGo scraper instead?**

You can, but a DuckDuckGo scraper is code you maintain: page changes break it, requests get blocked, and DuckDuckGo's terms govern how you collect data. The DuckDuckGo API gives you 3 endpoints of named JSON fields for 1 credit per successful call, and failed calls cost nothing. A scraper makes sense only for data these endpoints don't return, so check the response in the playground on this page first.

## Try the DuckDuckGo API with 100 free credits

No credit card. Failed calls are never billed.

[Get a free API key](https://perceptlayer.com/signup) [Read the docs](https://docs.perceptlayer.com)
