Everything
Search through millions of articles from over 50,000 large and small news sources and blogs. This includes breaking news as well as lesser articles.
This endpoint suits article discovery and analysis, but can be used to retrieve articles for display, too.
Live Examples
Request parameters
-
q
Keywords or phrases to search for in the article title and body.
Advanced search is supported here:
- Surround phrases with quotes (“) for exact match.
- Prepend words or phrases that must appear with a + symbol. Eg: +bitcoin
- Prepend words that must not appear with a – symbol. Eg: -bitcoin
- Alternatively you can use the AND / OR / NOT keywords, and optionally group these with parenthesis. Eg: crypto AND (ethereum OR litecoin) NOT bitcoin.
The complete value for
q
must be URL-encoded. -
qInTitle
Keywords or phrases to search for in the article title only.
Advanced search is supported here:
- Surround phrases with quotes (“) for exact match.
- Prepend words or phrases that must appear with a + symbol. Eg: +bitcoin
- Prepend words that must not appear with a – symbol. Eg: -bitcoin
- Alternatively you can use the AND / OR / NOT keywords, and optionally group these with parenthesis. Eg: crypto AND (ethereum OR litecoin) NOT bitcoin.
The complete value for
qInTitle
must be URL-encoded. -
sources
A comma-seperated string of identifiers (maximum 20) for the news sources or blogs you want headlines from. Use the /sources endpoint to locate these programmatically or look at the sources index.
-
domains
A comma-seperated string of domains (eg bbc.co.uk, techcrunch.com, engadget.com) to restrict the search to.
-
excludeDomains
A comma-seperated string of domains (eg bbc.co.uk, techcrunch.com, engadget.com) to remove from the results.
-
from
A date and optional time for the oldest article allowed. This should be in ISO 8601 format (e.g.
2020-11-17
or2020-11-17T11:12:57
) Default: the oldest according to your plan. -
to
A date and optional time for the newest article allowed. This should be in ISO 8601 format (e.g.
2020-11-17
or2020-11-17T11:12:57
) Default: the newest according to your plan. -
sortBy
The order to sort the articles in. Possible options:
relevancy
,popularity
,publishedAt
.
relevancy
= articles more closely related toq
come first.
popularity
= articles from popular sources and publishers come first.
publishedAt
= newest articles come first.
Default:publishedAt
-
pageSizeint
The number of results to return per page. 20 is the default, 100 is the maximum.
-
pageint
Use this to page through the results.
-
apiKeyREQUIRED
Your API key. Alternatively you can provide this via the
X-Api-Key
HTTP header.
Response object
-
statusstring
If the request was successful or not. Options:
ok
,error
. In the case oferror
acode
andmessage
property will be populated. -
totalResultsint
The total number of results available for your request. Only a limited number are shown at a time though, so use the
page
parameter in your requests to page through them. -
articlesarray[article]
The results of the request.
-
sourceobject
The identifier
id
and a display namename
for the source this article came from. -
authorstring
The author of the article
-
titlestring
The headline or title of the article.
-
descriptionstring
A description or snippet from the article.
-
urlstring
The direct URL to the article.
-
urlToImagestring
The URL to a relevant image for the article.
-
publishedAtstring
The date and time that the article was published, in UTC (+000)
-
contentstring
The unformatted content of the article, where available. This is truncated to 200 chars.
-