API Directory › 📰 News › New York Times
API KeyHTTPSCORS

New York Times API

Articles, book reviews, movie reviews and more from the NYT.

Category
Auth
API Key
HTTPS
Yes
CORS
Yes
Open New York Times docs ↗

What it does

The New York Times APIs cover Article Search (all articles back to 1851), Top Stories by section, Most Popular (emailed/shared/viewed), Times Wire (real-time feed), plus Books best-sellers, Movie Reviews, and more. You get metadata, abstracts and lead paragraphs — not full article text.

Base URL

https://api.nytimes.com/svc

Authentication

Create an account, register an app, enable the specific APIs you need, and pass the key as ?api-key=YOUR_KEY.

Code examples

curl
curl -s "https://api.nytimes.com/svc/topstories/v2/technology.json?api-key=$NYT_KEY"
Python (article search)
import requests

r = requests.get("https://api.nytimes.com/svc/search/v2/articlesearch.json",
    params={"q": "space telescope", "sort": "newest", "api-key": KEY}, timeout=10)
for doc in r.json()["response"]["docs"][:5]:
    print(doc["pub_date"][:10], doc["headline"]["main"])

Rate limits & quotas

Free tier: 500 requests/day and 5 requests/minute per API — the per-minute limit is strict, so add a delay between calls (Article Search especially). Over it returns HTTP 429. Article Search paginates 10 per page, up to page 100.

Key response fields

(Top Stories) results[].title / abstract / url / sectionHeadline, summary, link
(Top Stories) results[].multimedia[]Associated images at various sizes
(Article Search) response.docs[].headline.mainHeadline
(Article Search) response.docs[].snippet / lead_paragraphShort excerpt only — no full body
response.meta.hitsTotal matches for a search

Common errors

401Key missing, or the specific API not enabled for your app.
4295/minute or 500/day limit exceeded — throttle.
400Malformed fq filter query or begin_date (needs YYYYMMDD).

When to use it (and alternatives)

The pick for NYT-branded content, best-seller lists and film reviews. Because it never returns full text, pair it with your own summariser or just link out. For full body text choose The Guardian; for aggregation across outlets see newsdata.io.

FAQ

Can I get the full text of an article?

No. All NYT APIs return metadata plus an abstract or lead paragraph and the canonical URL. Full text is not licensed through the API.

Why do I keep hitting 429 with only a few calls?

The limit is 5 requests per minute per API, not just 500/day. Space calls at least ~12 seconds apart, or add exponential backoff.

Do I need to enable each API separately?

Yes — in the developer portal, add each API (Article Search, Top Stories, Books…) to your app. A key only works for the APIs you have enabled.

New to APIs?

Short guides for working with this API — and any other.

🛠️ Handy LarzOS tools

Free tools to help you work with this API.

JSON Formatter

Related News APIs

← Back

More News APIs · All 196 APIs