At RapidAPI, you can find APIs for just about any capability you need for your app. And in our blog we often highlight different types of APIs like chatbot APIs, identity data APIs, and weather APIs.
What is the best news API?
After reviewing over 60 news APIs, we found these 10 APIs to be the very best and worth mentioning:
- Google News API
- Bloomberg API
- News API
- New York Times API
- ESPN API
- Bing News API
- Guardian API
- BBC News API
- Yahoo News API
- Financial Times API
- https://newsapi.org/
Our Top 10 Best News APIs for 2021
Bing News Search | Best for News & Trending Topics | |
Contextual Web Search | Best for Searching News, Images & the Web | |
Newslit (formerly Nuzzel) | Best for Social News Search | |
Newscatcher | Best for Social News for Developers | |
Google News | Best for Google News | |
HackerNews | Best for Global News | |
NewsAPI | Best for All Around News | |
MyAllies Breaking News | Best for Real-time News | |
Guardian | Best for General News for US, UK & Australia | |
Financial Times | Best for Financial News & Blogs |
What is a news API?
An API is a set of definitions and protocols that allow technology products and services to communicate with each other.
A news API often refers to APIs that allow developers to request trending news, stories, and other information from these online news media publications.
You can browse the complete list of News APIs below and a few more listed on Wikipedia.
What is the best API?
The most popular API on RapidAPI is the Skyscanner API. You can see the most popular APIs here or check out trending APIs in this collection.
How many types of API are there?
There are four main types of APIs:
- Open APIs
- Partner APIs
- Internal APIs
- Composite APIs
Summary: Best News APIs for Developers
API | Main Functionality | Popularity Score | Latency | Success Rate |
---|---|---|---|---|
Bing News Search | Search News from Bing | 8.6/10 | 362ms | 99% |
Contextual Web Search | Search Engine for the Web, Images, and News | 9.6/10 | 5456ms | 95% |
Nuzzel News Search | Search for News | 7.9/10 | 113ms | 100% |
Newscatcher | Search for Top News | 9.5/10 | 376ms | 98% |
Google News | Search for Top News Headlines | 9.7/10 | 1275ms | 99% |
Hacker News | Access Hacker News stories, comments, and user data | 6.3/10 | 598ms | 100% |
NewsAPI | Access Global News from multiple sources | 8.6/10 | 427ms | 100% |
MyAllies Breaking News | Real-time financial news | 9.1/10 | 973ms | 87% |
Guardian | Get News from the Guardian | 5.8/10 | 239ms | 100% |
Financial Times | Financial news, blogs, and articles | 5.5/10 | 239ms | 100% |
News API Tutorials
21. NASA Open APIs
The NASA Open APIs is actually a collection of over a dozen APIs that provide tons of planetary weather information, satellite information, pictures, etc. Once you have obtained a free authorization key, you are limited to 1,000 requests per hour. One of my favorite APIs in this collection is the Astronomy Picture of the Day.
import requestsurl = "https://api.nasa.gov/planetary/apod?api_key=<YOUR_API_KEY>"
response = requests.get(url)
print(response.json())
Another free collection of APIs is the Open Library APIs. This collection allows us to search for all things related to books. It even allows multiple ways to find books, authors, subjects, and more by using names, ISBNs, OCLC, and LCCNs. You can even search for text within books!
import urllib
import requestsquery = "The Pragmatic Programmer"
query = urllib.parse.quote_plus(query)url = f"http://openlibrary.org/search.json?title={query}"
response = requests.get(url)
print(response.json())
Coin API is not completely free, but it does have a free tier you can use to get the latest market data for cryptocurrencies. Using the free version, you are limited to sending only 100 requests each day, however, upgrading to a higher tier can be done for a reasonable price.
import requestsurl = "https://rest.coinapi.io/v1/exchangerate/BTC/USD"
headers = {"X-CoinAPI-Key" : "<YOUR_API_KEY>"}response = requests.get(url, headers = headers)
print(response.json())
Another API that isn’t totally free but does have a free tier is the News API. This awesome tool allows you to obtain news articles from reputable news sources and blogs. Again, if you choose to use the free tier, you will be limited to the number of requests you can send as well as not getting new articles in real-time. However, this API can still be a great tool to add to your tool belt.
import requestsurl = "https://newsapi.org/v2/everything?q=cryptocurrency&apiKey=<YOUR_API_KEY>"
response = requests.get(url)
print(response.json())
Looking to enhance your experience on Spotify? Look no further because they have an API too. It only takes a few minutes to get a client id and secret for your application. Once you have that, there are tons of endpoints to use to get information on artists, albums, etc. Not only that, you can add/delete/update items in your playlists. For all you Python developers, there is a Spotipy module that makes it even easier to interact with the Spotify API.
import requests
import spotipy
from spotipy.oauth2 import SpotifyClientCredentialsclient_id = "<YOUR_CLIENT_ID>"
client_secret = "<YOUR_CLIENT_SECRET>"client_credentials_manager = SpotifyClientCredentials(client_id = client_id, client_secret = client_secret)spot = spotipy.Spotify(client_credentials_manager = client_credentials_manager)query = "1812 Overture"
search_result = spot.search(query, limit = 10, offset = 0, type = 'track', market = None)print(search_result)
Last, but not least, there is the Bored API. In a nutshell, the purpose of this fun API is to give you suggestions of activities you can do if you are bored.
import requestsurl = "https://www.boredapi.com/api/activity/"
response = requests.get(url)
print(response.json())