Support needed? Reach out! 📧

How to Scrape Youtube Channel Videos

This tutorial shows how to use Youtube Channel Videos API to scrape and crawl structured Youtube data in real-time.
Scrape all the videos of any YouTube channel including caption, statistics like view counts, metadata and more.

Access Youtube Data in 3 Steps

Start crawling Youtube channel videos data. Follow these steps to extract social media data in minutes.

1

Create Your Account

Go to our registration page and make an account. It's free, no credit card, and you get credits right away to play around with.

2

Verify Your Email Address

You'll get a verification email, click the link in it. Once that's done, you can grab your API token from the dashboard.

3

Make Your First API Call

Copy the code snippet below, swap in your API key, and run it. You'll get Youtube data back as JSON within a few seconds.

Code Sample

Here's a JavaScript example to get you going. Swap out the token and you're good, works the same way in any language that can make HTTP requests. Start collecting channel videos data via our REST API!

javascript-logo JavaScript
Youtube Channel Videos
1 const root = 'https://ensembledata.com/apis'
2 const endpoint = '/youtube/channel/videos'
3 const params = {
4   "browseId""UCnQghMm3Z164JFhScQYFTBw",
5   "depth"1,
6   "token""YOUR-TOKEN-HERE"
7 }
8  
9 const queryString = new URLSearchParams(params).toString();
10 const url = `${root}${endpoint}?${queryString}`;
11  
12 await fetch(url)
13   .then(response => response.json())
14   .then(data => console.log(data))
15   .catch(error => console.error(error));
16  

Parameters

browseId (string) Channel ID. REQUIRED
depth (integer) Abstraction of the API pagination. Depth 1 returns X results, depth N returns N * X results. Note that the exact number of results per depth (X) may differ per endpoint. Please refer to the specific endpoint description for more information. REQUIRED
token (string) Private token assigned to each client to access the APIs. REQUIRED

Example Response

Explore the fields returned by this endpoint. Click a row to expand nested objects and arrays, hover a value to copy it, or use "Expand all" to see everything at once.

JSON
Youtube Channel Videos
dataobject2 fields
userobject24 fields
urlCanonicalstring"https://www.youtube.com/channel/UCnQghMm3Z164JFhScQYFTBw"
titlestring"Alisha Revel"
descriptionstring"WASSUP Y'ALL! I'm so happy that you're here. From cooking videos, to V…"
thumbnailobject1 field
thumbnailsarray1 item · schema from #0 1 item
urlstring"https://yt3.ggpht.com/Gh0T4D9hwMcgCEWy_ebLp9ygA6W959S08xWLWRWeqebKH4AS…"
widthnumber200
heightnumber200
siteNamestring"YouTube"
appNamestring"YouTube"
androidPackagestring"com.google.android.youtube"
iosAppStoreIdstring"544007664"
iosAppArgumentsstring"https://www.youtube.com/channel/UCnQghMm3Z164JFhScQYFTBw"
ogTypestring"yt-fb-app:channel"
urlApplinksWebstring"https://www.youtube.com/channel/UCnQghMm3Z164JFhScQYFTBw?feature=appli…"
urlApplinksIosstring"vnd.youtube://www.youtube.com/channel/UCnQghMm3Z164JFhScQYFTBw?feature…"
urlApplinksAndroidstring"vnd.youtube://www.youtube.com/channel/UCnQghMm3Z164JFhScQYFTBw?feature…"
urlTwitterIosstring"vnd.youtube://www.youtube.com/channel/UCnQghMm3Z164JFhScQYFTBw?feature…"
urlTwitterAndroidstring"vnd.youtube://www.youtube.com/channel/UCnQghMm3Z164JFhScQYFTBw?feature…"
twitterCardTypestring"summary"
twitterSiteHandlestring"@YouTube"
schemaDotOrgTypestring"http://schema.org/http://schema.org/YoutubeChannelV2"
noindexbooleanfalse
unlistedbooleanfalse
familySafebooleantrue
tagsarray24 items · schema from #0 24 items
0string"f"
1string"a"
2string"s"
3string"h"
4string"i"
5string"o"
6string"n"
availableCountriesarray249 items · schema from #0 249 items
0string"K"
1string"Z"
linkAlternatesarray3 items · schema from #0 3 items
hrefUrlstring"https://m.youtube.com/channel/UCnQghMm3Z164JFhScQYFTBw"
videosarray1 item · schema from #0 1 item
richItemRendererobject2 fields
contentobject1 field
videoRendererobject14 fields
videoIdstring"htOWSRj4KgE"
thumbnailobject1 field
thumbnailsarray4 items · schema from #0 4 items
urlstring"https://i.ytimg.com/vi/htOWSRj4KgE/hqdefault.jpg?sqp=-oaymwEbCKgBEF5IV…"
widthnumber168
heightnumber94
titleobject2 fields
runsarray1 item · schema from #0 1 item
textstring"DID I RLY JUST SAY THAT? CHITCHAT GRWM"
accessibilityobject1 field
accessibilityDataobject1 field
labelstring"DID I RLY JUST SAY THAT? CHITCHAT GRWM by Alisha Revel 22 hours ago 2…"
descriptionSnippetobject1 field
runsarray1 item · schema from #0 1 item
textstring"UGH. I love the moments when I get vulnerable with you. We shouldn't …"
publishedTimeTextobject1 field
simpleTextstring"22 hours ago"
lengthTextobject2 fields
accessibilityobject1 field
accessibilityDataobject1 field
labelstring"26 minutes, 23 seconds"
simpleTextstring"26:23"
viewCountTextobject1 field
simpleTextstring"384 views"
navigationEndpointobject3 fields
clickTrackingParamsstring"CK8BENwwIhMIx7WhwdK3-wIVhelgCh247AgBWhhVQ25RZ2hNbTNaMTY0SkZoU2NRWUZUQn…"
commandMetadataobject1 field
webCommandMetadataobject3 fields
urlstring"/watch?v=htOWSRj4KgE"
webPageTypestring"WEB_PAGE_TYPE_WATCH"
rootVenumber3832
watchEndpointobject2 fields
videoIdstring"htOWSRj4KgE"
watchEndpointSupportedOnesieConfigobject1 field
html5PlaybackOnesieConfigobject1 field
commonConfigobject1 field
urlstring"https://rr3---sn-ab5sznlk.googlevideo.com/initplayback?source=youtube&…"
trackingParamsstring"CK8BENwwIhMIx7WhwdK3-wIVhelgCh247AgBQIHU4MeRyeXphgGqARpVVUxGblFnaE1tM1…"
showActionMenubooleanfalse
shortViewCountTextobject2 fields
accessibilityobject1 field
accessibilityDataobject1 field
labelstring"384 views"
simpleTextstring"384 views"
menuobject1 field
menuRendererobject3 fields
itemsarray1 item · schema from #0 1 item
menuServiceItemRendererobject4 fields
textobject1 field
runsarray1 item · schema from #0 1 item
textstring"Add to queue"
iconobject1 field
iconTypestring"ADD_TO_QUEUE_TAIL"
serviceEndpointobject3 fields
clickTrackingParamsstring"CLIBEP6YBBgGIhMIx7WhwdK3-wIVhelgCh247AgB"
commandMetadataobject1 field
webCommandMetadataobject1 field
sendPostbooleantrue
signalServiceEndpointobject2 fields
signalstring"CLIENT_SIGNAL"
actionsarray1 item · schema from #0 1 item
clickTrackingParamsstring"CLIBEP6YBBgGIhMIx7WhwdK3-wIVhelgCh247AgB"
addToPlaylistCommandobject5 fields
openMiniplayerbooleantrue
videoIdstring"htOWSRj4KgE"
listTypestring"PLAYLIST_EDIT_LIST_TYPE_QUEUE"
onCreateListCommandobject3 fields
clickTrackingParamsstring"CLIBEP6YBBgGIhMIx7WhwdK3-wIVhelgCh247AgB"
commandMetadataobject1 field
webCommandMetadataobject2 fields
sendPostbooleantrue
apiUrlstring"/youtubei/v1/playlist/create"
createPlaylistServiceEndpointobject2 fields
videoIdsarray1 item · schema from #0 1 item
0string"h"
1string"t"
2string"O"
3string"W"
4string"S"
5string"R"
6string"j"
7string"4"
8string"K"
9string"g"
10string"E"
paramsstring"CAQ%3D"
videoIdsarray1 item · schema from #0 1 item
0string"h"
1string"t"
2string"O"
3string"W"
4string"S"
5string"R"
6string"j"
7string"4"
8string"K"
9string"g"
10string"E"
trackingParamsstring"CLIBEP6YBBgGIhMIx7WhwdK3-wIVhelgCh247AgB"
trackingParamsstring"CK8BENwwIhMIx7WhwdK3-wIVhelgCh247AgB"
accessibilityobject1 field
accessibilityDataobject1 field
labelstring"Action menu"
thumbnailOverlaysarray4 items · schema from #0 4 items
thumbnailOverlayTimeStatusRendererobject2 fields
textobject2 fields
accessibilityobject1 field
accessibilityDataobject1 field
labelstring"26 minutes, 23 seconds"
simpleTextstring"26:23"
stylestring"DEFAULT"
richThumbnailobject1 field
movingThumbnailRendererobject3 fields
movingThumbnailDetailsobject2 fields
thumbnailsarray1 item · schema from #0 1 item
urlstring"https://i.ytimg.com/an_webp/htOWSRj4KgE/mqdefault_6s.webp?du=3000&sqp=…"
widthnumber320
heightnumber180
logAsMovingThumbnailbooleantrue
enableHoveredLoggingbooleantrue
enableOverlaybooleantrue
trackingParamsstring"CK4BEJmNBRgAIhMIx7WhwdK3-wIVhelgCh247AgB"

Response Codes

Status codes this endpoint can return, so you can handle errors before they surprise you in production.

200SuccessSuccessful Response
422Client ErrorValidation Error
491Client ErrorToken not found
492Client ErrorEmail not verified
493Client ErrorSubscription expired
495Client ErrorAll daily units used
500Server ErrorSomething went wrong

API Pricing

#returned_videos / 10 units Cost per successful call to this endpoint.
Example Cases
1
Depth 1 Result: 22 videos
3 units
2
Depth 5 but channel has only 20 videos Result: 20 videos
2 units
3
Depth 50 Result: 100 videos
10 units
4
Depth 100 Result: 2000 videos
200 units

Fetch Youtube Data at Scale

Access complete YouTube video feeds for any channel and use the data to inform your content strategy or research workflows.

deco-icon

Video Catalog

Paginate through a channel's entire public video catalog.

deco-icon

Titles & Views

Get titles, descriptions, and view counts for every video.

deco-icon

Publish Dates

See publish dates returned to track upload timing patterns.