YouTube Video API
Everything public about one video in a single call: exact counts, the full description, tags, chapters and the channel behind it.
- 100 free credits
- No card needed
- No Google Cloud project or OAuth
curl "https://pipefetch.com/v1/youtube/video?video=jNQXAC9IVRw" \
-H "x-api-key: YOUR_API_KEY"const res = await fetch('https://pipefetch.com/v1/youtube/video?video=jNQXAC9IVRw', {
headers: { 'x-api-key': process.env.PIPEFETCH_API_KEY },
});
const { data, credits } = await res.json();import os, requests
res = requests.get(
"https://pipefetch.com/v1/youtube/video",
params={"video": "jNQXAC9IVRw"},
headers={"x-api-key": os.environ["PIPEFETCH_API_KEY"]},
)
data = res.json()["data"]What you get
- Exact view, like and comment counts
- Title, full description, category, tags and hashtags
- Publish time, duration, chapters and thumbnail
- Live, upcoming, age-restricted and comments-off flags
- The channel: id, handle, verification and subscriber count
{
"data": {
"videoId": "jNQXAC9IVRw",
"url": "https://www.youtube.com/watch?v=jNQXAC9IVRw",
"title": "Me at the zoo",
"description": "Microplastics are accumulating in human brains at an alarming rate\nhttps://www.youtube.com/watch?v=0PT5c1z3LL8\n\n“Nanoplastics and Human Health” with M…",
"publishedAt": "2005-04-24T03:31:52.000Z",
"durationSeconds": 19,
"viewCount": 448773635,
"likeCount": 20141346,
"commentCount": 10644331,
"category": "Film & Animation",
"keywords": [
"me at the zoo",
"jawed karim"
],
"hashtags": [],
"chapters": [
{
"title": "Intro",
"startSeconds": 0
},
{
"title": "The cool thing",
"startSeconds": 5
}
],
"thumbnailUrl": "https://i.ytimg.com/vi/jNQXAC9IVRw/hqdefault.jpg",
"isLive": false,
"isUpcoming": false,
"isFamilySafe": true,
"isAgeRestricted": false,
"commentsTurnedOff": false,
"channel": {
"id": "UC4QobU6STFB0P71PMvOGN5A",
"name": "jawed",
"handle": "@jawed",
"url": "https://www.youtube.com/@jawed",
"isVerified": true,
"avatarUrl": "https://yt3.ggpht.com/uI3VE4PVqvCy0xnWLqMJnEzyBUm3T8VHOCp4ee-1RxdHqKXCdUE_qXYQnpf9AfuEoIPactVyDhM=s800-c-k-c0x00ffffff-no-rj",
"subscriberCount": 6740000
}
},
"credits": {
"used": 1,
"remaining": 99
}
}One GET request
Everything the endpoint accepts. The full reference, with the complete example response, is in the docs.
GET/v1/youtube/video
Costs 1 credit per request. Only requests that return data are charged.
Parameters
| Name | Type | Description |
|---|---|---|
videorequired |
string | Video URL or 11-character video id. Watch, youtu.be, Shorts, embed and live links all work. |
Good to know
- View, like and comment counts are the exact numbers, not the rounded labels YouTube displays.
What people build with it
Track performance over time
Call the endpoint on a schedule and store the exact counts to see how a video grows.
Enrich a list of videos
Turn a spreadsheet of video links into titles, channels, durations and statistics.
Content analysis
Study the tags, descriptions and chapter structure that successful videos in a niche use.
Buy credits once. Use them whenever.
This endpoint costs 1 credit per request, and a request that returns no data costs nothing. Move the slider to see what your volume costs.
One credit is one request that returns data. Requests that return nothing are free.
- $2.42 per 1,000 requests
- About $12.08 a month at this pace
- Lasts about 2.4 months at this pace
- Credits never expire
Questions and answers
Are the counts exact or rounded?
Exact. You get 448773635, not "448M views".
Which links can I pass?
A watch link, a youtu.be link, a Shorts link, an embed or live link, or just the 11-character video id.
Does it return dislikes?
No. YouTube stopped publishing dislike counts in 2021, so no public source has them.
What happens with private or deleted videos?
The request answers 404 video_not_found and costs nothing.
What does a request cost?
One request costs 1 credit. Credit packs start at $9 for 3,000 credits, never expire, and a request that returns no data is not charged. New accounts get 100 free credits without a card.
Step-by-step guides
How to get a YouTube transcript in Python
Three working ways, with code: a free library, yt-dlp and an HTTP API, and where each one stops working.
Read the guideYouTube API quota exceeded: what the error means and how to fix it
How Google counts quota today, why search runs out first, and seven ways to stay under the limit or get past it.
Read the guide
More YouTube APIs
-
1 credit
YouTube Transcript API
The transcript of any public video with captions, as plain text, timestamped segments, SRT or WebVTT.
GET /v1/youtube/transcript -
1 credit
YouTube Channel API
Subscribers, video count, description, keywords and avatar for a channel, from a handle, id or URL.
GET /v1/youtube/channel -
1 credit
YouTube Channel Videos API
The latest uploads of a channel, newest first, with views, duration and publish time.
GET /v1/youtube/channel/videos -
1 credit
YouTube Shorts API
The Shorts of a channel, newest first, with view counts and thumbnails.
GET /v1/youtube/channel/shorts -
1 credit
YouTube Search API
YouTube search results for a query, with the same sorting and filters the site offers.
GET /v1/youtube/search -
1 credit / 20
YouTube Comments API
Top or newest comments of a video with likes, reply counts, pinned and hearted flags.
GET /v1/youtube/comments
Make your first request in a minute
Sign in, copy your key and call an endpoint. Your account starts with 100 free credits.