Getting Started

Introduction

Our API was developed to provide global news from thousands of sources with exceptional response times. On average we add over 1 million articles weekly, so you will never be short of content. Even better, it is completely free!

To get started simply sign up and use your API token in any of the available API endpoints documented below for instant access.

If you have any questions or concerns, feel free to contact us.

Authentication

As mentioned above, when you sign up for free you will find your API token on your dashboard. Simply add this to any of our API endpoints as a GET parameter to gain access. Examples of how this is done can be found below.

API Endpoints

Headlines Available on: Standard plan and above

Endpoint

GET https://api.thenewsapi.com/v1/news/headlines HTTP/1.1

Use this endpoint to find get the latest headlines by category along with similar articles, allowing you to create the perfect news aggregation page similar to Google News .

If you have issues with your requests, please ensure your GET parameters are URL-encoded.

All text data returned is UTF-8.

All dates are in UTC (GMT).

HTTP GET Parameters

name required description
api_token true Your API token which can be found on your account dashboard.
locale false Comma separated list of country codes to include in the result set. Default is all countries. Click here for a list of supported countries.
Example: us,ca (US + Canada).
domains false Comma separated list of domains to include. List of domains can be obtained through our Sources endpoint, found further down this page.
exclude_domains false Comma separated list of domains to exclude
source_ids false Comma separated list of source_ids to include. List of source_ids can be obtained through our Sources endpoint, found further down this page.
exclude_source_ids false Comma separated list of source_ids to exclude.
language false Comma separated list of languages to include. Default is all.
Click here for a list of supported languages.
Examples: en,es (English + Spanish)
published_on false Find headlines for articles published on the specified date. Supported formats include: Y-m-d.
Examples: 2025-03-28
headlines_per_category false Specify the number of articles you want to return per category. The maximum is 10 and the default is 6.
include_similar false Specify if you wish to include similar articles with each base article. Default is true.

Response Objects

name description
data > uuid The unique identifier for an article in our system. Store this and use it to find specific articles using our single article endpoint.
data > title The article title.
data > description The article meta description.
data > keywords The article meta keywords.
data > snippet The first 60 characters of the article body.
data > url The URL to the article.
data > image_url The URL to the article image.
data > language The language of the source.
data > published_at The datetime the article was published.
data > source The domain of the source.
data > categories Array of strings which the source is categorized as.
data > locale Locale of the source.
data > similar An array of similar articles to the base article.

If no results are found, the data object will be empty.

Example Request

GET https://api.thenewsapi.com/v1/news/headlines?locale=us&language=en&api_token=YOUR_API_TOKEN

Example Response

{
    "data": {
        "general": [
            {
                "uuid": "4809fbf7-b7ee-4e6c-865c-767c0ad717d0",
                "title": "Why are we still giving federal money to DEI-peddling consultants?",
                "description": "Consulting firms receiving federal dollars must stop practicing their DEI initiatives.",
                "keywords": "",
                "snippet": "NEW You can now listen to Fox News articles!\n\nPresident Trump has made laudable gains against the diversity-industrial complex, but marquee consulting firms con...",
                "url": "https://www.foxnews.com/opinion/why-we-still-giving-federal-money-dei-peddling-consultants",
                "image_url": "https://static.foxnews.com/foxnews.com/content/uploads/2025/03/trumpdei.png",
                "language": "en",
                "published_at": "2025-03-28T09:00:52.000000Z",
                "source": "foxnews.com",
                "categories": [
                    "general",
                    "politics"
                ],
                "locale": "us",
                "similar": [
                    {
                        "uuid": "ae013f51-5319-4b9f-b1a3-7a601ebfb846",
                        "title": "University of Michigan announces it's shuttering its DEI offices due to Trump's executive orders",
                        "description": "The University of Michigan is closing the doors of its diversity, equity, and inclusion (DEI) office.",
                        "keywords": "",
                        "snippet": "The University of Michigan announced it will be closing the doors of its diversity, equity, and inclusion (DEI) office on Thursday.\n\nIn a message to the univers...",
                        "url": "https://www.foxnews.com/media/university-michigan-announces-its-shuttering-its-dei-offices-due-trumps-executive-orders",
                        "image_url": "https://static.foxnews.com/foxnews.com/content/uploads/2024/10/university-of-michigan.jpg",
                        "language": "en",
                        "published_at": "2025-03-28T01:08:37.000000Z",
                        "source": "foxnews.com",
                        "categories": [
                            "general",
                            "politics"
                        ],
                        "locale": "us"
                    },
                    {
                        "uuid": "6fa6e6a4-adac-4f79-9eaf-e3b613cd91c2",
                        "title": "Federal court warns Pentagon not to act against transgender service members during appeal",
                        "description": "A federal court of appeals circuit in D.C. warned the Trump administration to not act against transgender servicemembers while a potential ban is working through the court system.",
                        "keywords": "",
                        "snippet": "The Trump administration was warned by the U.S. Court of Appeals for the District of Columbia Circuit on Thursday to not act against transgender military member...",
                        "url": "https://www.foxnews.com/politics/federal-court-warns-pentagon-not-act-against-transgender-service-members-during-appeal",
                        "image_url": "https://static.foxnews.com/foxnews.com/content/uploads/2025/02/trans-pentagon.png",
                        "language": "en",
                        "published_at": "2025-03-28T02:20:38.000000Z",
                        "source": "foxnews.com",
                        "categories": [
                            "general",
                            "politics"
                        ],
                        "locale": "us"
                    },
                    {
                        "uuid": "2328fd06-f4a7-4008-a054-2809ec0f27f3",
                        "title": "A federal judge temporarily blocks parts of Trump's anti-DEI executive orders",
                        "description": "A federal judge has temporarily blocked the U.S. Department of Labor from implementing parts of President Donald Trump’s executive orders aimed at curbing diversity, equity and inclusion efforts among federal contractors and grant recipients",
                        "keywords": "Legal proceedings, Sexual assault, Race and ethnicity, Diversity, equity and inclusion, Executive orders, Politics, Lawsuits, U.S. news, General news, Business, Article, 120244536",
                        "snippet": "A federal judge has temporarily blocked the U.S. Department of Labor from implementing parts of President Donald Trump’s executive orders aimed at curbing div...",
                        "url": "https://abcnews.go.com/US/wireStory/federal-judge-temporarily-blocks-parts-trumps-anti-dei-120244536",
                        "image_url": "https://i.abcnewsfe.com/a/39cd503c-4725-4cd3-bac3-45ee2f45d6cb/wirestory_d84ed0d8d77146f27570595513046ae5_16x9.jpg?w=1600",
                        "language": "en",
                        "published_at": "2025-03-28T02:54:26.000000Z",
                        "source": "abcnews.go.com",
                        "categories": [
                            "general",
                            "politics"
                        ],
                        "locale": "us"
                    },
                    {
                        "uuid": "bda368fb-d634-40dc-b5e2-8854cb3447d0",
                        "title": "Federal judge to consider releasing immigration activist who took refuge in churches",
                        "description": "A federal judge in Denver is set to hear arguments Friday over whether an immigration and labor activist who took refuge in Colorado churches to avoid deportation during the first Trump administration should be freed from detention.",
                        "keywords": "",
                        "snippet": "DENVER — A federal judge in Denver is set to hear arguments Friday over whether an immigration and labor activist who took refuge in Colorado churches to avoi...",
                        "url": "https://www.nbcnews.com/news/us-news/federal-judge-consider-releasing-immigration-activist-took-refuge-chur-rcna198517",
                        "image_url": "https://media-cldnry.s-nbcnews.com/image/upload/t_nbcnews-fp-1200-630,f_auto,q_auto:best/rockcms/2025-03/250328-Jeanette-Vizguerra-mb-0754-1adebb.jpg",
                        "language": "en",
                        "published_at": "2025-03-28T07:58:17.000000Z",
                        "source": "nbcnews.com",
                        "categories": [
                            "general",
                            "politics"
                        ],
                        "locale": "us"
                    }
                ]
            },
            {
                "uuid": "94e5b50c-5ff1-4dc7-9cac-95ec11d3495e",
                "title": "Selena Quintanilla's killer, Yolanda Saldívar, denied parole",
                "description": "Selena Quintanilla's killer, Yolanda Saldívar, was denied parole by the Texas pardons board Thursday. Saldívar fatally shot Quintanilla-Pérez March 31, 1995.",
                "keywords": "",
                "snippet": "Music icon Selena Quintanilla-Pérez's killer, Yolanda Saldívar, was denied parole by Texas' parole board Thursday.\n\nSaldívar has been serving a life sentence...",
                "url": "https://www.foxnews.com/entertainment/selena-quintanillas-killer-yolanda-saldivar-denied-parole",
                "image_url": "https://static.foxnews.com/foxnews.com/content/uploads/2025/03/selena.jpg",
                "language": "en",
                "published_at": "2025-03-28T00:34:44.000000Z",
                "source": "foxnews.com",
                "categories": [
                    "general",
                    "politics"
                ],
                "locale": "us",
                "similar": [
                    {
                        "uuid": "e58d667f-1af1-42c6-8b60-4767d0512d68",
                        "title": "Selena Quintanilla-Perez’s Killer Yolanda Saldivar Denied Parole",
                        "description": "Yolanda Saldivar, who killed singer Selena Quintanilla-Perez in March 1995, received a decision on her parole 30 years after the murder",
                        "keywords": "",
                        "snippet": "Three decades after Selena Quintanilla-Pérez’s murder, her convicted killer, Yolanda Saldívar, has been denied parole.\n\nThe Texas Board of Pardons and Parol...",
                        "url": "https://www.usmagazine.com/celebrity-news/news/selena-quintanilla-perezs-killer-yolanda-saldivar-denied-parole/",
                        "image_url": "https://www.usmagazine.com/wp-content/uploads/2025/03/Selenas-Killer-Yolanda-Saldivar-Eligible-for-Parole-2.jpg?crop=0px,0px,2000px,1051px&resize=1200,630&quality=62&strip=all",
                        "language": "en",
                        "published_at": "2025-03-28T00:00:53.000000Z",
                        "source": "usmagazine.com",
                        "categories": [
                            "entertainment",
                            "general"
                        ],
                        "locale": "us"
                    },
                    {
                        "uuid": "3d5e3990-9b51-4ae4-aec0-29b9d40a0302",
                        "title": "Yolanda Saldivar, woman who killed music icon Selena in 1995, has been denied parole",
                        "description": "The woman convicted of killing Tejano music legend Selena Quintanilla-Perez has been denied parole after spending decades behind bars for fatally shooting the young singer at a Texas motel in 1995.",
                        "keywords": "US News, murders, parole, Selena Quintanilla",
                        "snippet": "The woman convicted of killing Tejano music legend Selena Quintanilla-Perez has been denied parole after spending decades behind bars for fatally shooting the y...",
                        "url": "https://nypost.com/2025/03/27/us-news/yolanda-saldivar-woman-who-killed-music-icon-selena-in-1995-has-been-denied-parole/",
                        "image_url": "https://nypost.com/wp-content/uploads/sites/2/2025/03/101232565.jpg?quality=75&strip=all&w=1024",
                        "language": "en",
                        "published_at": "2025-03-28T00:32:00.000000Z",
                        "source": "nypost.com",
                        "categories": [
                            "general"
                        ],
                        "locale": "us"
                    }
                ]
            }
        ],
        "business": ...,
        "sports": ...,
        "tech": ...,
        "science": ...,
        "health": ...
    }
}

Top Stories Available on: All plans

Endpoint

GET https://api.thenewsapi.com/v1/news/top HTTP/1.1

Use this endpoint to find live and historical top stories around the world or filter to get only top stories for specific countries. Filtering by language, category, source and publish date is also possible, as well as advanced searching on title and the main text of the article.

If you have issues with your requests, please ensure your GET parameters are URL-encoded.

All text data returned is UTF-8.

All dates are in UTC (GMT).

HTTP GET Parameters

name required description
api_token true Your API token which can be found on your account dashboard.
search false Use the search as a basic search tool by entering regular search terms or it has more advanced usage to build search queries:
+ signifies AND operation
| signifies OR operation
- negates a single token
" wraps a number of tokens to signify a phrase for searching
* at the end of a term signifies a prefix query
( and ) signify precedence

To use one of these characters literally, escape it with a preceding backslash (\).

Example 1: forex + (usd | gbp) -cad (searches for forex articles which include usd or gbp but excludes cad)
Example 2: "Apple Inc" (searches for articles with exact matches for "Apple Inc")

For more advanced query examples, see our API Examples section.

When using special characters (+, -, |, ", *, ()) you MUST URL-encode this parameter.
search_fields false Comma separated list of fields to apply the search parameter to.
Supported fields: title | description | keywords | main_text
Example: title,description,keywords
Default: title,main_text
locale false Comma separated list of country codes to include in the result set. Default is all countries. Click here for a list of supported countries.
Example: us,ca (US + Canada).
categories false Comma separated list of categories to include.
Supported categories: general | science | sports | business | health | entertainment | tech | politics | food | travel
Example: business,tech
exclude_categories false Comma separated list of categories to exclude.
domains false Comma separated list of domains to include. List of domains can be obtained through our Sources endpoint, found further down this page.
exclude_domains false Comma separated list of domains to exclude
source_ids false Comma separated list of source_ids to include. List of source_ids can be obtained through our Sources endpoint, found further down this page.
exclude_source_ids false Comma separated list of source_ids to exclude.
language false Comma separated list of languages to include. Default is all.
Click here for a list of supported languages.
Examples: en,es (English + Spanish)
published_before false Find all articles published before the specified date. Supported formats include: Y-m-d\TH:i:s | Y-m-d\TH:i | Y-m-d\TH | Y-m-d | Y-m | Y.
Examples: 2025-03-28T11:49:31 | 2025-03-28T11:49 | 2025-03-28T11 | 2025-03-28 | 2025-03 | 2025
published_after false Find all articles published after the specified date. Supported formats include: Y-m-d\TH:i:s | Y-m-d\TH:i | Y-m-d\TH | Y-m-d | Y-m | Y.
Examples: 2025-03-28T11:49:31 | 2025-03-28T11:49 | 2025-03-28T11 | 2025-03-28 | 2025-03 | 2025
published_on false Find all articles published on the specified date. Supported formats include: Y-m-d.
Examples: 2025-03-28
sort false Sort by published_on or relevance_score (only available when used in conjunction with search). Default is published_at unless search is used and sorting by published_at is not included, in which case relevance_score is used.
limit false Specify the number of articles you want to return in the request. The maximum limit is based on your plan. The default limit is the maximum specified for your plan.
page false Use this to paginate through the result set. Default is 1. Note that the max result set can't exceed 20,000. For example if your limit is 50, the max page you can have is 400 (50 * 400 = 20,000).
Example: page=2

Response Objects

name description
meta > found The number of articles found for the request.
meta > returned The number of articles returned on the page. This is useful to determine the end of the result set as if this is lower than limit, there are no more articles after this page.
meta > limit The limit based on the limit parameter.
meta > page The page number based on the page parameter.
data > uuid The unique identifier for an article in our system. Store this and use it to find specific articles using our single article endpoint.
data > title The article title.
data > description The article meta description.
data > keywords The article meta keywords.
data > snippet The first 60 characters of the article body.
data > url The URL to the article.
data > image_url The URL to the article image.
data > language The language of the source.
data > published_at The datetime the article was published.
data > source The domain of the source.
data > categories Array of strings which the source is categorized as.
data > relevance_score Relevance score based on the search parameter. If the search parameter is not used, this will be null.
data > locale Locale of the source.

If no results are found, the data object will be empty.

Example Request

GET https://api.thenewsapi.com/v1/news/top?api_token=YOUR_API_TOKEN&locale=us&limit=3

Example Response

{
    "meta": {
        "found": 1271472,
        "returned": 10,
        "limit": 10,
        "page": 1
    },
    "data": [
        {
            "uuid": "f7003742-e8d0-45ab-9243-6693d4ce04e3",
            "title": "Sean ‘Diddy’ Combs accused of forcing male photographer to perform oral sex in scathing new lawsuit",
            "description": "The man, only identified as John Doe, claims the Bad Boy Records founder started chatting to him while he was working on the \"high-profile\" commercial in late 2...",
            "keywords": "US News, Sean 'Diddy' Combs, sexual assaults",
            "snippet": "Sean “Diddy” Combs has been accused in a new lawsuit of forcing a male photographer to give him oral sex on the set of a commercial — with the promise of ...",
            "url": "https://nypost.com/2025/03/28/us-news/sean-diddy-combs-forced-male-photographer-to-perform-oral-sex-lawsuit/",
            "image_url": "https://nypost.com/wp-content/uploads/sites/2/2025/03/diddy-combs-sexual-assault-photographer-comp.jpg?quality=75&strip=all&w=1024",
            "language": "en",
            "published_at": "2025-03-28T11:34:34.000000Z",
            "source": "nypost.com",
            "categories": [
                "general"
            ],
            "relevance_score": null,
            "locale": "us"
        },
        {
            "uuid": "fd00390c-c135-4cd7-bff1-208235f2a658",
            "title": "New York Dragons hire Long Island native as head coach in search of local talent",
            "description": "The New York Dragons have introduced Long Island football great Gerald Filardi as head coach ahead of the arena football team’s inaugural year in the Entertai...",
            "keywords": "Sports, Long Island, arena football, dragons",
            "snippet": "These dragons have a new master.\n\nThe New York Dragons have introduced Long Island football great Gerald Filardi as head coach ahead of the arena football team?...",
            "url": "https://nypost.com/2025/03/28/sports/new-york-dragons-hire-long-island-native-as-head-coach-in-search-of-local-talent/",
            "image_url": "https://nypost.com/wp-content/uploads/sites/2/2025/03/new-york-dragons-entertainment-football-101235905.jpg?quality=75&strip=all&w=1024",
            "language": "en",
            "published_at": "2025-03-28T11:30:00.000000Z",
            "source": "nypost.com",
            "categories": [
                "general"
            ],
            "relevance_score": null,
            "locale": "us"
        },
        {
            "uuid": "7bf22da0-691b-4500-bb0a-3e9e86a8dc58",
            "title": "Bangkok declares 'disaster zone', buildings evacuated after Myanmar earthquake",
            "description": "The Stock Exchange of Thailand suspended trading across all exchanges on Friday while Honda and Nissan temporarily halted plant operations.",
            "keywords": "Natural disasters, Weather, Honda Motor Co Ltd, Nissan Motor Co Ltd, Nissan Motor Co Ltd, business news",
            "snippet": "Thai rescue workers arrive on scene at a construction building collapse in the Chatuchak area following an earthquake on March 28, 2025 in Bangkok, Thailand.\n\nB...",
            "url": "https://www.cnbc.com/2025/03/28/myanmar-earthquake-bangkok-declares-disaster-zone-buildings-evacuated.html",
            "image_url": "https://image.cnbcfm.com/api/v1/image/108122660-1743157987040-gettyimages-2207313175-1o0a8946_44757f18-3581-45f8-bbbb-bc8a0eaffeb3.jpeg?v=1743157996&w=1920&h=1080",
            "language": "en",
            "published_at": "2025-03-28T11:28:22.000000Z",
            "source": "cnbc.com",
            "categories": [
                "general",
                "business"
            ],
            "relevance_score": null,
            "locale": "us"
        },
        {
            "uuid": "54184d33-b275-4424-ac85-44ea9996bd1b",
            "title": "Trump administration pulls Elise Stefanik’s nomination for UN",
            "description": "President Donald Trump announced his administration has pulled Rep. Elise Stefanik for ambassador to the United Nation. NBC’s Garrett Haake reports for TODAY ...",
            "keywords": "",
            "snippet": "\n\nCopied\n\nPresident Donald Trump announced his administration has pulled Rep. Elise Stefanik for ambassador to the United Nation. NBC’s Garrett Haake reports ...",
            "url": "https://www.today.com/video/trump-pulls-elise-stefanik-s-nomination-for-un-ambassador-235658309546",
            "image_url": "https://media-cldnry.s-nbcnews.com/image/upload/t_social_share_1200x630_center,f_auto,q_auto:best/mpx/2704722219/2025_03/1743161265081_tdy_news_7a_haake_un_250328_1920x1080-pj77p1.jpg",
            "language": "en",
            "published_at": "2025-03-28T11:27:51.000000Z",
            "source": "nbcnews.com",
            "categories": [
                "politics",
                "general"
            ],
            "relevance_score": null,
            "locale": "us"
        },
        {
            "uuid": "7490877c-24c8-4b8e-801e-e7b6c182355f",
            "title": "Trump administration rejects Putin's proposal that the UN governs Ukraine",
            "description": "The White House on Thursday dismissed Russia's Putin's suggestion that peace talks in Ukraine depend on it being governed by the UN while elections are held.",
            "keywords": "",
            "snippet": "Create your free profile or log in to save this article\n\nCreate your free profile or log in to save this article\n\nThe White House on Thursday dismissed Russian ...",
            "url": "https://www.nbcnews.com/news/world/putin-trump-russia-ukraine-zelenskyy-un-guinea-timor-yugoslavia-rcna198520",
            "image_url": "https://media-cldnry.s-nbcnews.com/image/upload/t_nbcnews-fp-1200-630,f_auto,q_auto:best/rockcms/2025-03/250328-ukraine-mb-0827-5c19ff.jpg",
            "language": "en",
            "published_at": "2025-03-28T11:24:58.000000Z",
            "source": "nbcnews.com",
            "categories": [
                "general",
                "politics"
            ],
            "relevance_score": null,
            "locale": "us"
        },
        {
            "uuid": "01bd2e10-4389-419a-97bd-732bde615155",
            "title": "Elon Musk suggests DOGE’s work may be wrapped up by Day 130",
            "description": "Elon Musk and several members of his Department of Government Efficiency are speaking out together for the first time during an interview on Fox News. Musk sugg...",
            "keywords": "",
            "snippet": "\n\nCopied\n\nElon Musk and several members of his Department of Government Efficiency are speaking out together for the first time during an interview on Fox News....",
            "url": "https://www.today.com/video/elon-musk-and-doge-staff-speak-out-on-cost-cutting-campaign-235658309532",
            "image_url": "https://media-cldnry.s-nbcnews.com/image/upload/t_social_share_1200x630_center,f_auto,q_auto:best/mpx/2704722219/2025_03/1743161018755_tdy_news_7a_haake_doge_250328_1920x1080-68pukf.jpg",
            "language": "en",
            "published_at": "2025-03-28T11:23:44.000000Z",
            "source": "nbcnews.com",
            "categories": [
                "politics",
                "general"
            ],
            "relevance_score": null,
            "locale": "us"
        },
        {
            "uuid": "4a2eeea8-2930-4dbc-beaf-2b9b759dee3e",
            "title": "Babysitter stabs 3-year-old girl to death in Las Vegas: police",
            "description": "A babysitter has been arrested for allegedly stabbing to death the 3-year-old girl she was minding in Las Vegas, police said.",
            "keywords": "",
            "snippet": "A babysitter has been arrested for allegedly stabbing to death the 3-year-old girl she was minding in Las Vegas, police said.\n\nMarketta Phillips, 41, has been c...",
            "url": "https://www.foxnews.com/us/babysitter-stabs-3-year-old-girl-death-las-vegas-police",
            "image_url": "https://static.foxnews.com/foxnews.com/content/uploads/2023/09/lvmpd.png",
            "language": "en",
            "published_at": "2025-03-28T11:23:31.000000Z",
            "source": "foxnews.com",
            "categories": [
                "general",
                "politics"
            ],
            "relevance_score": null,
            "locale": "us"
        },
        {
            "uuid": "6239fd5d-6583-4a0b-a9d1-3e74cd3a08e2",
            "title": "Walz says Dems weren't 'bold enough' to double down on DEI, immigration",
            "description": "Minnesota Gov. Tim Walz said the Democratic Party has gotten into \"this mess\" because it wasn’t \"bold enough\" to stand up for diversity, equity and inclusion ...",
            "keywords": "",
            "snippet": "Minnesota Gov. Tim Walz said the Democratic Party has gotten into its current mess because it wasn’t \"bold enough\" to stand up for diversity, equity and inclu...",
            "url": "https://www.foxnews.com/politics/walz-says-dems-werent-bold-enough-double-down-dei-immigration",
            "image_url": "https://static.foxnews.com/foxnews.com/content/uploads/2025/03/tim-walz.jpg",
            "language": "en",
            "published_at": "2025-03-28T11:20:58.000000Z",
            "source": "foxnews.com",
            "categories": [
                "general",
                "politics"
            ],
            "relevance_score": null,
            "locale": "us"
        },
        {
            "uuid": "c136ad8b-8266-463c-92f2-290795230385",
            "title": "Dramatic Pictures Emerge From Earthquake In Thailand & Myanmar As Hundreds Feared Dead",
            "description": "The Thailand and Myanmar earthquake has led to dramatic pictures including a rooftop swimming pool as hundreds feared dead.",
            "keywords": "",
            "snippet": "The eyes of the world’s news media are trained on Thailand and Myanmar, where a devastating 7.7 magnitude earthquake has left hundreds feared dead.\n\nThe Unite...",
            "url": "https://deadline.com/2025/03/thailand-myanmar-earthquake-dramatic-images-hundreds-feared-dead-1236353283/",
            "image_url": "https://deadline.com/wp-content/uploads/2025/03/GettyImages-2206632875.jpg?w=1024",
            "language": "en",
            "published_at": "2025-03-28T11:20:25.000000Z",
            "source": "deadline.com",
            "categories": [
                "entertainment"
            ],
            "relevance_score": null,
            "locale": "us"
        },
        {
            "uuid": "369e1688-254f-459d-b167-f9acdb167f46",
            "title": "Indian Premier League Broadcast On JioStar Shatters Viewership Records In Opening Week",
            "description": "The Indian Premier League (IPL) launch on Jiostar brought record-breaking viewership figures from its opening week.",
            "keywords": "",
            "snippet": "Jiostar unveiled record-breaking viewership figures from the opening week of its TATA Indian Premier League (IPL) 2025 broadcast.\n\nKicking off on March 22, the ...",
            "url": "https://deadline.com/2025/03/indian-premier-league-broadcast-jiostar-shatters-viewership-records-1236353277/",
            "image_url": "https://deadline.com/wp-content/uploads/2025/03/GettyImages-2206328590.jpg?w=1024",
            "language": "en",
            "published_at": "2025-03-28T11:19:29.000000Z",
            "source": "deadline.com",
            "categories": [
                "entertainment"
            ],
            "relevance_score": null,
            "locale": "us"
        }
    ]
}

All News Available on: All plans

Endpoint

GET https://api.thenewsapi.com/v1/news/all HTTP/1.1

Use this endpoint to find all live and historical articles we collect. Filtering by language, category, source and publish date is also possible, as well as advanced searching on title and the main text of the article.

If you have issues with your requests, please ensure your GET parameters are URL-encoded.

All text data returned is UTF-8.

All dates are in UTC (GMT).

HTTP GET Parameters

name required description
api_token true Your API token which can be found on your account dashboard.
search false Use the search as a basic search tool by entering regular search terms or it has more advanced usage to build search queries:
+ signifies AND operation
| signifies OR operation
- negates a single token
" wraps a number of tokens to signify a phrase for searching
* at the end of a term signifies a prefix query
( and ) signify precedence

To use one of these characters literally, escape it with a preceding backslash (\).

Example 1: forex + (usd | gbp) -cad (searches for forex articles which include usd or gbp but excludes cad)
Example 2: "Apple Inc" (searches for articles with exact matches for "Apple Inc")

For more advanced query examples, see our API Examples section.

When using special characters (+, -, |, ", *, ()) you MUST URL-encode this parameter.
search_fields false Comma separated list of fields to apply the search parameter to.
Supported fields: title | description | keywords | main_text
Example: title,description,keywords
Default: title,main_text
categories false Comma separated list of categories to include.
Supported categories: general | science | sports | business | health | entertainment | tech | politics | food | travel
Example: business,tech
exclude_categories false Comma separated list of categories to exclude.
domains false Comma separated list of domains to include. List of domains can be obtained through our Sources endpoint, found further down this page.
exclude_domains false Comma separated list of domains to exclude
source_ids false Comma separated list of source_ids to include. List of source_ids can be obtained through our Sources endpoint, found further down this page.
exclude_source_ids false Comma separated list of source_ids to exclude.
language false Comma separated list of languages to include. Default is all.
Click here for a list of supported languages.
Examples: en,es (English + Spanish)
published_before false Find all articles published before the specified date. Supported formats include: Y-m-d\TH:i:s | Y-m-d\TH:i | Y-m-d\TH | Y-m-d | Y-m | Y.
Examples: 2025-03-28T11:49:31 | 2025-03-28T11:49 | 2025-03-28T11 | 2025-03-28 | 2025-03 | 2025
published_after false Find all articles published after the specified date. Supported formats include: Y-m-d\TH:i:s | Y-m-d\TH:i | Y-m-d\TH | Y-m-d | Y-m | Y.
Examples: 2025-03-28T11:49:31 | 2025-03-28T11:49 | 2025-03-28T11 | 2025-03-28 | 2025-03 | 2025
published_on false Find all articles published on the specified date. Supported formats include: Y-m-d.
Examples: 2025-03-28
sort false Sort by published_on or relevance_score (only available when used in conjunction with search). Default is published_at unless search is used and sorting by published_at is not included, in which case relevance_score is used.
limit false Specify the number of articles you want to return in the request. The maximum limit is based on your plan. The default limit is the maximum specified for your plan.
page false Use this to paginate through the result set. Default is 1. Note that the max result set can't exceed 20,000. For example if your limit is 50, the max page you can have is 400 (50 * 400 = 20,000).
Example: page=2

Response Objects

name description
meta > found The number of articles found for the request.
meta > returned The number of articles returned on the page. This is useful to determine the end of the result set as if this is lower than limit, there are no more articles after this page.
meta > limit The limit based on the limit parameter.
meta > page The page number based on the page parameter.
data > uuid The unique identifier for an article in our system. Store this and use it to find specific articles using our single article endpoint.
data > title The article title.
data > description The article meta description.
data > keywords The article meta keywords.
data > snippet The first 60 characters of the article body.
data > url The URL to the article.
data > image_url The URL to the article image.
data > language The language of the source.
data > published_at The datetime the article was published.
data > source The domain of the source.
data > categories Array of strings which the source is categorized as.
data > relevance_score Relevance score based on the search parameter. If the search parameter is not used, this will be null.

If no results are found, the data object will be empty.

Example Request

GET https://api.thenewsapi.com/v1/news/all?api_token=YOUR_API_TOKEN&language=en&limit=3

Example Response

{
    "meta": {
        "found": 51610535,
        "returned": 10,
        "limit": 10,
        "page": 1
    },
    "data": [
        {
            "uuid": "3723b33d-89b6-4038-ab55-cac673f39088",
            "title": "충주 청소년 복지에 팔 걷은 국원라이온스클럽",
            "description": "[충청투데이 김의상 기자] 충주 국원라이온스클럽이 28일 충주시여자중장기청소년쉼터에 청소년들의 건강한 성장을 위?...",
            "keywords": "충주시, 의료비 100만원 전달, 청소년쉼터, 국원라이온스클럽",
            "snippet": "충주 국원라이온스클럽 최윤영 (오른쪽 두번째)회장이 28일 충주시여자중장기청소년쉼터에 의료비 100만원 전달했다.사?...",
            "url": "https://www.cctoday.co.kr/news/articleView.html?idxno=2209883",
            "image_url": "https://cdn.cctoday.co.kr/news/photo/202503/2209883_655605_5002.jpg",
            "language": "ko",
            "published_at": "2025-03-28T11:49:57.000000Z",
            "source": "cctoday.co.kr",
            "categories": [
                "general"
            ],
            "relevance_score": null
        },
        {
            "uuid": "d00f8224-2713-4b33-a24b-5274c2c7c4d0",
            "title": "백종원 대표",
            "description": "백종원 더본코리아 대표이사는 상장사에 걸맞은 모습과 조직을 갖추겠다고 밝혔다.백종원 대표는 28일 서초구 스페이스?...",
            "keywords": "",
            "snippet": "백종원 대표\n\n[출처: 연합뉴스 자료사진]\n\n(서울=연합인포맥스) 김용갑 기자 = 백종원 더본코리아 대표이사는 상장사에 걸...",
            "url": "https://news.einfomax.co.kr/news/articleView.html?idxno=4348643",
            "image_url": "https://cdn.news.einfomax.co.kr/news/thumbnail/202503/4348643_227247_503_v150.jpg",
            "language": "ko",
            "published_at": "2025-03-28T11:49:12.000000Z",
            "source": "news.einfomax.co.kr",
            "categories": [
                "general"
            ],
            "relevance_score": null
        },
        {
            "uuid": "e37445b3-cb58-4cdb-8712-4b5917a48fcf",
            "title": "恒风商业物业ABS项目状态为“已受理” 发行金额4.61亿元",
            "description": "上述债券发行人为义乌市恒风新能源服务有限公司,拟发行总额为人民币4.61亿元,债券品种为资产支持证券(ABS),承销...",
            "keywords": "观点新媒体, 博鳌房地产论坛, 2024博鳌房地产论坛, 行业网站",
            "snippet": "",
            "url": "https://www.guandian.cn:443/article/20250328/476573.html",
            "image_url": "https://www.guandian.cn/statics/index2016/img/ewm.png",
            "language": "zh",
            "published_at": "2025-03-28T11:49:12.000000Z",
            "source": "guandian.cn",
            "categories": [],
            "relevance_score": null
        },
        {
            "uuid": "136720bc-2021-45eb-9839-ec00f80ce372",
            "title": "Premier Japonii: cła USA na auta będą miały \"niezwykle duży wpływ\" na naszą gospodarkę",
            "description": "Ogłoszone przez prezydenta USA Donalda Trumpa  dodatkowe 25-procentowe cła na import samochodów będą miały \"niezwykle  duży wpływ\" na gospodarkę Japoni...",
            "keywords": "",
            "snippet": "\"Zastanowimy się nad najskuteczniejszymi środkami, aby Stany Zjednoczone zrozumiały, że nie będzie to dla nich korzystne\" – oświadczył Ishiba, przemawi...",
            "url": "https://www.pb.pl/premier-japonii-cla-usa-na-auta-beda-mialy-niezwykle-duzy-wplyw-na-nasza-gospodarke-1238918",
            "image_url": "https://images.pb.pl/filtered/3f12d1b0-c7aa-432f-bf43-a7e7f35713ca/222eac6f-a08d-4523-abf8-fc290691cfff_og_1200_630.jpg",
            "language": "pl",
            "published_at": "2025-03-28T11:48:24.000000Z",
            "source": "pb.pl",
            "categories": [
                "business"
            ],
            "relevance_score": null
        },
        {
            "uuid": "f69af959-3900-40b8-95c4-5753a39343f1",
            "title": "NFL draft: Inside Elic Ayomanor's viral night, journey from Canada",
            "description": "From Medicine Hat, Alberta, the Stanford receiver came along way to a record night against Travis Hunter and his NFL future.",
            "keywords": "",
            "snippet": "Elic Ayomanor somehow grabs the touchdown and keeps both hands on the ball in overtime. (0:21)\n\nOpen Extended Reactions\n\nJust about everyone in Elic Ayomanor's ...",
            "url": "https://www.espn.com/nfl/draft2025/story/_/id/44418464/2025-nfl-draft-elic-ayomanor-canada-journey-stanford-travis-hunter",
            "image_url": "https://a3.espncdn.com/combiner/i?img=/photo/2025/0326/r1469788_2_1296x729_16-9.jpg",
            "language": "en",
            "published_at": "2025-03-28T11:48:11.000000Z",
            "source": "espn.com",
            "categories": [
                "sports"
            ],
            "relevance_score": null
        },
        {
            "uuid": "e52d8a58-b988-4ac5-a5e2-c16e08681fad",
            "title": "“게보린·하루엔진 야구팬 접점 늘린다” 삼진제약, KBO와 디지털 스폰서십 체결",
            "description": "삼진제약은 한국야구위원회(KBO)와 ‘디지털 스폰서십’을 체결하고 대표 품목인 효과 빠른 해열진통제 ‘게보린 정’과...",
            "keywords": "삼진제약, KBO, 디지털, 스폰서십, 게보린, 하루엔진",
            "snippet": "조규석 삼진제약 대표(왼쪽)와 허구연 KBO 총재가 지난 27일 KBO사옥에서 디지털 스폰서십을 체결했다. [사진 삼진제약]\n\n삼...",
            "url": "https://www.nbnews.kr/news/articleView.html?idxno=106946",
            "image_url": "https://cdn.nbnews.kr/news/thumbnail/202503/106946_126615_2450_v150.jpg",
            "language": "ko",
            "published_at": "2025-03-28T11:48:07.000000Z",
            "source": "greendaily.co.kr",
            "categories": [],
            "relevance_score": null
        },
        {
            "uuid": "967704f4-2931-443b-9f4a-990d7226f894",
            "title": "Reporter ohne Grenzen für Informationsfreiheit",
            "description": "",
            "keywords": "",
            "snippet": "Die künftige Bundesregierung muss Exilmedien und unabhängige Redaktionen in Osteuropa, Asien und anderen Regionen der Welt stärker unterstützen. Das fordert...",
            "url": "https://www.reporter-ohne-grenzen.de/pressemitteilungen/meldung/koalition-muss-unabhaengige-medien-weltweit-staerken",
            "image_url": "https://www.reporter-ohne-grenzen.de/fileadmin/Redaktion/_processed_/a/5/csm_250327_Koalitionsverhandlungen_picture-alliance_dts-Agentur__515319395_6e798fec82.jpg",
            "language": "de",
            "published_at": "2025-03-28T11:48:00.000000Z",
            "source": "reporter-ohne-grenzen.de",
            "categories": [
                "general"
            ],
            "relevance_score": null
        },
        {
            "uuid": "4a351aaf-1538-42bf-b164-9a09237fa44c",
            "title": "Marché: toujours plombé par les tensions commerciales",
            "description": "Les Bourses européennes cèdent encore du terrain ce vendredi (-0,1% à Londres, -0,6% à Francfort et à Paris), la perspective de guerre commerciale ent",
            "keywords": "",
            "snippet": "(CercleFinance.com) - Les Bourses européennes cèdent encore du terrain ce vendredi (-0,1% à Londres, -0,6% à Francfort et à Paris), la perspective de guerr...",
            "url": "https://www.abcbourse.com/marches/marche-toujours-plombe-par-les-tensions-commerciales_660022",
            "image_url": "https://www.abcbourse.com/imgabc/720-x.jpg",
            "language": "fr",
            "published_at": "2025-03-28T11:48:00.000000Z",
            "source": "abcbourse.com",
            "categories": [
                "business"
            ],
            "relevance_score": null
        },
        {
            "uuid": "cfd548c7-9bf0-4e4a-b5b0-fac550546f3a",
            "title": "El futuro suena así: voz, IA y la reinvención de las marcas",
            "description": "por Ismael Perona Luna\r\n\r\nAún puedo sentirte a ti y a las palabras de nuestra historia. Theodore se enamoró de Samantha sin haberla visto nunca. No necesitó...",
            "keywords": "marketing, publicidad, comunicación, producción, investigación, fotografía, mobile, diseño, creatividad, arte, estrategia publicitaria, planner, consumo, advertainment, marcas, branded content, transmedia, medios, anuncios, publicistas, control de publici",
            "snippet": "por Ismael Perona Luna\n\nAún puedo sentirte a ti y a las palabras de nuestra historia. Theodore se enamoró de Samantha sin haberla visto nunca. No necesitó un...",
            "url": "https://www.elpublicista.es/noticia-destacada/futuro-suena-asi-voz-ia-reinvencion-marcas",
            "image_url": "https://www.elpublicista.es/adjuntos/fichero_42392_20250327.jpg",
            "language": "es",
            "published_at": "2025-03-28T11:48:00.000000Z",
            "source": "elpublicista.es",
            "categories": [],
            "relevance_score": null
        },
        {
            "uuid": "167e3280-c242-464a-989e-b89845ce74bd",
            "title": "박성민 의원, 국민의힘 산불재난대응 특별위원회 위원에 임명",
            "description": "[뉴스데일리]국민의힘 박성민 국회의원(울산 중구, 산자중기위 간사)은 27일 ‘국민의힘 산불재난대응 특별위원회’ 위?...",
            "keywords": "",
            "snippet": "박성민 국민의힘 의원\n\n[뉴스데일리]국민의힘 박성민 국회의원(울산 중구, 산자중기위 간사)은 27일 ‘국민의힘 산불재난...",
            "url": "http://www.newsdaily.kr/news/articleView.html?idxno=245404",
            "image_url": "https://cdn.newsdaily.kr/news/thumbnail/202503/245404_156507_4726_v150.jpg",
            "language": "ko",
            "published_at": "2025-03-28T11:47:51.000000Z",
            "source": "newsdaily.kr",
            "categories": [],
            "relevance_score": null
        }
    ]
}

Similar News Available on: All plans

Endpoint

GET https://api.thenewsapi.com/v1/news/similar/uuid HTTP/1.1

Use this endpoint to find similar stories to a specific article based on its UUID.

If you have issues with your requests, please ensure your GET parameters are URL-encoded.

All text data returned is UTF-8.

All dates are in UTC (GMT).

HTTP GET Parameters

name required description
api_token true Your API token which can be found on your account dashboard.
categories false Comma separated list of categories to include.
Supported categories: general | science | sports | business | health | entertainment | tech | politics | food | travel
Example: business,tech
exclude_categories false Comma separated list of categories to exclude.
domains false Comma separated list of domains to include. List of domains can be obtained through our Sources endpoint, found further down this page.
exclude_domains false Comma separated list of domains to exclude
source_ids false Comma separated list of source_ids to include. List of source_ids can be obtained through our Sources endpoint, found further down this page.
exclude_source_ids false Comma separated list of source_ids to exclude.
language false Comma separated list of languages to include. Default is all.
Click here for a list of supported languages.
Examples: en,es (English + Spanish)
published_before false Find all articles published before the specified date. Supported formats include: Y-m-d\TH:i:s | Y-m-d\TH:i | Y-m-d\TH | Y-m-d | Y-m | Y.
Examples: 2025-03-28T11:49:31 | 2025-03-28T11:49 | 2025-03-28T11 | 2025-03-28 | 2025-03 | 2025
published_after false Find all articles published after the specified date. Supported formats include: Y-m-d\TH:i:s | Y-m-d\TH:i | Y-m-d\TH | Y-m-d | Y-m | Y.
Examples: 2025-03-28T11:49:31 | 2025-03-28T11:49 | 2025-03-28T11 | 2025-03-28 | 2025-03 | 2025
published_on false Find all articles published on the specified date. Supported formats include: Y-m-d.
Examples: 2025-03-28
limit false Specify the number of articles you want to return in the request. The maximum limit is based on your plan. The default limit is the maximum specified for your plan.
page false Use this to paginate through the result set. Default is 1. Note that the max result set can't exceed 20,000. For example if your limit is 50, the max page you can have is 400 (50 * 400 = 20,000).
Example: page=2

Response Objects

name description
meta > found The number of articles found for the request.
meta > returned The number of articles returned on the page. This is useful to determine the end of the result set as if this is lower than limit, there are no more articles after this page.
meta > limit The limit based on the limit parameter.
meta > page The page number based on the page parameter.
data > uuid The unique identifier for an article in our system. Store this and use it to find specific articles using our single article endpoint.
data > title The article title.
data > description The article meta description.
data > keywords The article meta keywords.
data > snippet The first 60 characters of the article body.
data > url The URL to the article.
data > image_url The URL to the article image.
data > language The language of the source.
data > published_at The datetime the article was published.
data > source The domain of the source.
data > categories Array of strings which the source is categorized as.
data > relevance_score Relevance score based on the article provided.

If no results are found, the data object will be empty.

Example Request

GET https://api.thenewsapi.com/v1/news/similar/cc11e3ab-ced0-4a42-9146-e426505e2e67?api_token=YOUR_API_TOKEN&language=en&published_on=2020-12-01

Example Response

{
   "meta": {
      "found": 3571,
      "returned": 3,
      "limit": 3,
      "page": 1
   },
   "data": [
      {
         "uuid": "df4ad427-a672-4c67-b6c6-6f81aa00e164",
         "title": "Tesla stock jumps after announcement it will join S&P 500 in one go",
         "description": "Tesla's stock price surged early Tuesday after the company b...",
         "keywords": "Business, s&p 500, stocks, tesla",
         "snippet": "Tesla’s stock price surged early Tuesday after the company...",
         "url": "https://nypost.com/2020/12/01/tesla-stock-jumps-on-news-it-will-join-sp-500-in-one-shot/",
         "image_url": "https://nypost.com/wp-content/uploads/sites/2/2020/12/tesla-52.jpg?quality=90&strip=all&w=1200",
         "language": "en",
         "published_at": "2020-12-01T14:35:46.000000Z",
         "source": "nypost.com",
         "categories": [
            "business"
         ],
         "relevance_score": 153.61266
      },
      {
         "uuid": "c9a23881-12dd-4005-8982-7b6552a2eb50",
         "title": "Tesla To Join S&P 500 With Full Market Cap On December 21",
         "description": "Tesla will be added to the S&P 500 index all at once at its ...",
         "keywords": "Tesla, S&P500, EV, Automotive, Stocks, Investing",
         "snippet": "Tesla (NASDAQ: TSLA) will be added to the S&P 500 index all ...",
         "url": "https://oilprice.com/Latest-Energy-News/World-News/Tesla-To-Join-SP-500-With-Full-Market-Cap-On-December-21.html",
         "image_url": "https://d32r1sh890xpii.cloudfront.net/news/718x300/2020-12-01_xwjdajwctl.jpg",
         "language": "en",
         "published_at": "2020-12-01T16:30:00.000000Z",
         "source": "oilprice.com",
         "categories": [
            "general",
            "business"
         ],
         "relevance_score": 146.92773
      },
      {
         "uuid": "18afdb1c-7742-4016-bf8c-a2f114e11199",
         "title": "Tesla to Enter S&P 500 at Full Weight in December",
         "description": "The electric-vehicle maker will be added to the broad stock-...",
         "keywords": "Motor Vehicles, Alternative Fuel Vehicles, Trusts Funds Financial Vehicles, Diversified Holding Companies, Automotive",
         "snippet": "S&P Dow Jones Indices said it will add Tesla Inc.’s full w...",
         "url": "https://www.wsj.com/articles/tesla-to-enter-s-p-500-at-full-weight-in-december-11606780897?mod=pls_whats_news_us_business_f",
         "image_url": "https://images.wsj.net/im-265933/social",
         "language": "en",
         "published_at": "2020-12-01T00:01:00.000000Z",
         "source": "online.wsj.com",
         "categories": [
            "business"
         ],
         "relevance_score": 128.22346
      }
   ]
}

News by UUID Available on: All plans

Endpoint

GET https://api.thenewsapi.com/v1/news/uuid/uuid HTTP/1.1

Use this endpoint to find specific articles by the UUID which is returned on our search endpoints. This is useful if you wish to store the UUID to return the article later.

If you have issues with your requests, please ensure your GET parameters are URL-encoded.

All text data returned is UTF-8.

All dates are in UTC (GMT).

HTTP GET Parameters

name required description
api_token true Your API token which can be found on your account dashboard.

Response Objects

name description
uuid The unique identifier for an article in our system. Store this and use it to find specific articles using our single article endpoint.
title The article title.
description The article meta description.
keywords The article meta keywords.
snippet The first 60 characters of the article body.
url The URL to the article.
image_url The URL to the article image.
language The language of the source.
published_at The datetime the article was published.
source The domain of the source.
categories Array of strings which the source is categorized as.

If no results are found, a resource_not_found error will be returned.

Example Request

GET https://api.thenewsapi.com/v1/news/uuid/147013d8-6c2c-4d50-8bad-eb3c8b7f5740?api_token=YOUR_API_TOKEN

Example Response

{
    "uuid": "147013d8-6c2c-4d50-8bad-eb3c8b7f5740",
    "title": "These Are The Four American Companies Worth Over $1 Trillion Each – 24",
    "description": "America’s major market indexes set records in the early pa...",
    "keywords": "",
    "snippet": "These Are The Four American Companies Worth Over $1 Trillion...",
    "url": "https://247wallst.com/investing/2020/10/17/these-are-the-four-american-companies-worth-over-1-trillion-each/",
    "image_url": "https://247wallst.com/wp-content/uploads/2020/08/imageForEntry2-Qrj.jpg",
    "language": "en",
    "published_at": "2020-10-17T11:16:20.000000Z",
    "source": "247wallst.com",
    "categories": [
        "business"
    ]
}

Sources Available on: All plans

Endpoint

GET https://api.thenewsapi.com/v1/news/sources HTTP/1.1

Use this endpoint to sources to use in your news API requests. Note that the limit is 50 for all requests.

If you have issues with your requests, please ensure your GET parameters are URL-encoded.

All text data returned is UTF-8.

HTTP GET Parameters

name required description
categories false Comma separated list of categories to include
Example: business,tech
exclude_categories false Comma separated list of categories to exclude
language false Comma separated list of languages to include. Default is all.
Click here for a list of supported languages.
Examples: en,es (English + Spanish)
page false Use this to paginate through the result set. Default is 1.
Example: page=2

Response Objects

name description
meta > found The number of sources found for the request.
meta > returned The number of sources returned on the page.
meta > limit The limit is 50. This currently can not be changed.
meta > page The page number based on the page parameter.
data > source_id The unique ID of the source feed. Use this for the source_ids or exclude_source_ids parameters in the news endpoints. There may be many source_ids for each domain, therefore we would generally suggest using the domains filter instead the source_ids filter.
data > domain The domain of the source. You can use this for the domains or exclude_domains parameters in the news endpoints.
data > language The source language.
data > locale The source locale. Note that only select sources have locales.
data > categories Array of strings which the source is categorized as.

If no results are found, the data object will be empty.

Example Request

GET https://api.thenewsapi.com/v1/news/sources?api_token=YOUR_API_TOKEN&language=en

Example Response

{
    "meta": {
        "found": 15453,
        "returned": 50,
        "limit": 50,
        "page": 1
    },
    "data": [
        {
            "source_id": "arstechnica.com-1",
            "domain": "arstechnica.com",
            "language": "en",
            "locale": null,
            "categories": [
                "tech"
            ]
        },
        {
            "source_id": "adweek.com-1",
            "domain": "adweek.com",
            "language": "en",
            "locale": null,
            "categories": [
                "business"
            ]
        },
        ...

Errors

Errors

If your request was unsuccessful, you will receive a JSON formatted error. Below you will find the potential errors you may encounter when using the API.

Errors

error code HTTP status description
malformed_parameters 400 Validation of parameters failed. The failed parameters are usually shown in the error message.
invalid_api_token 401 Invalid API token.
usage_limit_reached 402 Usage limit of your plan has been reached. Usage limit and remaining requests can be found on the X-UsageLimit-Limit header.
endpoint_access_restricted 403 Access to the endpoint is not available on your current subscription plan.
resource_not_found 404 Resource could not be found.
invalid_api_endpoint 404 API route does not exist.
rate_limit_reached 429 Too many requests in the past 60 seconds. Rate limit and remaining requests can be found on the X-RateLimit-Limit header.
server_error 500 A server error occured.
maintenance_mode 503 The service is currently under maintenance.

Example Error Response

{
    "error": {
        "code": "malformed_parameters",
        "message": "The published_before parameter(s) are incorrectly formatted."
    }
}

Examples

API Examples

Our endpoints are very useful for filtering to find only specific resources you need. Follow each example request below to see how you can build dynamic queries.

Example Request 1

This is a basic request which will return all articles which match the search term "usd" within the title or body of the article:

GET https://api.thenewsapi.com/v1/news/all?api_token=YOUR_API_TOKEN&search=usd

Example Request 2

This will return all articles which match the search term "usd" OR "gbp":

GET https://api.thenewsapi.com/v1/news/all?api_token=YOUR_API_TOKEN&search=usd | gbp

Example Request 3

This will return all articles which match the search term "usd" AND "gbp":

GET https://api.thenewsapi.com/v1/news/all?api_token=YOUR_API_TOKEN&search=usd + gbp

Example Request 4

This will return all articles which match the search term "usd" AND "gbp" but removes any articles which mentions "cad":

GET https://api.thenewsapi.com/v1/news/all?api_token=YOUR_API_TOKEN&search=usd + gbp -cad

Example Request 5

This will return all articles which match the search term "forex" AND "usd" OR "gbp" but removes any articles which mentions "cad":

GET https://api.thenewsapi.com/v1/news/all?api_token=YOUR_API_TOKEN&search=forex + (usd | gbp) -cad

Example Request 6

This is the same as Example Request 5 but will also ensure the articles returned are in English and categorized by business or tech but not travel, and are published within the last week:

GET https://api.thenewsapi.com/v1/news/all?api_token=YOUR_API_TOKEN&search=forex + (usd | gbp) -cad&language=en&categories=business,tech&exclude_categories=travel&published_after=2025-03-21

Code Examples

See our prepared examples below to quickly get started implementing our API into your next project.

PHP

$queryString = http_build_query([
    'api_token' => 'YOUR_API_TOKEN',
    'categories' => 'business,tech',
    'search' => 'apple',
    'limit' => 50,
]);

$ch = curl_init(sprintf('%s?%s', 'https://api.thenewsapi.com/v1/news/all', $queryString));
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);

$json = curl_exec($ch);

curl_close($ch);

$apiResult = json_decode($json, true);

print_r($apiResult);

Python

# Python 3
import http.client, urllib.parse

conn = http.client.HTTPSConnection('api.thenewsapi.com')

params = urllib.parse.urlencode({
    'api_token': 'YOUR_API_TOKEN',
    'categories': 'business,tech',
    'limit': 50,
    })

conn.request('GET', '/v1/news/all?{}'.format(params))

res = conn.getresponse()
data = res.read()

print(data.decode('utf-8'))

Go

package main

import (
    "fmt"
    "io/ioutil"
    "net/http"
    "net/url"
)

func main() {
    baseURL, _ := url.Parse("https://thenewsapi.com")

    baseURL.Path += "v1/news/all"

    params := url.Values{}
    params.Add("api_token", "YOUR_API_TOKEN")
    params.Add("categories", "business,tech")
    params.Add("search", "apple")
    params.Add("limit", "50")

    baseURL.RawQuery = params.Encode()

    req, _ := http.NewRequest("GET", baseURL.String(), nil)

    res, _ := http.DefaultClient.Do(req)

    defer res.Body.Close()

    body, _ := ioutil.ReadAll(res.Body)

    fmt.Println(string(body))
}

JavaScript

var requestOptions = {
    method: 'GET'
};

var params = {
    api_token: 'YOUR_API_TOKEN',
    categories: 'business,tech',
    search: 'apple',
    limit: '50'
};

var esc = encodeURIComponent;
var query = Object.keys(params)
    .map(function(k) {return esc(k) + '=' + esc(params[k]);})
    .join('&');

fetch("https://api.thenewsapi.com/v1/news/all?" + query, requestOptions)
  .then(response => response.text())
  .then(result => console.log(result))
  .catch(error => console.log('error', error));

C#

var client = new RestClient("https://api.thenewsapi.com/v1/news/all");
client.Timeout = -1;

var request = new RestRequest(Method.GET);

request.AddQueryParameter("api_token", "YOUR_API_TOKEN");
request.AddQueryParameter("categories", "business,tech");
request.AddQueryParameter("search", "apple");
request.AddQueryParameter("limit", "50");

IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);

Java

OkHttpClient client = new OkHttpClient().newBuilder()
  .build();

HttpUrl.Builder httpBuilder = HttpUrl.parse("https://api.thenewsapi.com/v1/news/all").newBuilder();
httpBuilder.addQueryParameter("api_token", "YOUR_API_TOKEN");
httpBuilder.addQueryParameter("categories", "business,tech");
httpBuilder.addQueryParameter("search", "apple");
httpBuilder.addQueryParameter("limit", "50");

Request request = new Request.Builder().url(httpBuilder.build()).build();

Response response = client.newCall(request).execute();