Developer tutorial
How to scrape YouTube channels with cURL (2026)
This tutorial shows how to scrape YouTube channels in cURL using the SocialCrawl API. You get a channel's subscriber count, total views, video count, description, country, and thumbnails by handle, channel id, or URL from one GET request, with no YouTube developer account, proxies, or HTML parsing. The code below is runnable as-is, and the response underneath it is a real, unedited call.
Code tested July 2026
How it works
- 1Get a free API keyCreate a SocialCrawl account and copy your API key from the dashboard. Every new account starts with free credits.
- 2Set up cURLUse curl, which ships with macOS, Linux, and Windows 10 and later.
- 3Call the YouTube Channel endpointSend a GET request to /v1/youtube/channel with your API key in the x-api-key header and the `handle` parameter.
- 4Read the responseParse the JSON. SocialCrawl returns a channel's subscriber count, total views, video count, description, country, and thumbnails by handle, channel id, or URL in one normalized schema, so you write no HTML parsing or proxy code.
The code
A real, unedited response from the request above.
curl -G "https://www.socialcrawl.dev/v1/youtube/channel" \
-H "x-api-key: YOUR_API_KEY" \
--data-urlencode "handle=MrBeast"[ RESPONSE ]
{
"success": true,
"platform": "youtube",
"endpoint": "/v1/youtube/channel",
"data": {
"author": {
"id": "UCX6OQ3DkcsbYNE6H8uQQuVA",
"username": "@mrbeast",
"display_name": "MrBeast",
"avatar_url": "https://yt3.ggpht.com/nxYrc_1_2f77DoBadyxMTmv7ZpRZapHR5jbuYe7PlPd5cIRJxtNNEYyOC0ZsxaDyJJzXrnJiuDE=s800-c-k-c0x00ffffff-no-rj",
"bio": "SUBSCRIBE FOR A COOKIE!\nNew MrBeast or MrBeast Gaming video every single Saturday at noon eastern time!\nAccomplishments:\n- Raised $20,000,000 To Plant 20,000,000 Trees\n- Removed 30,000,000 pounds of trash from the ocean\n- Helped 2,000 people walk again\n- Helped 1,000 blind people see\n- Helped 1,000 deaf people hear\n- Built wells in Africa\n- Built and gave away 100 houses\n- Adopted every dog in a shelter (twice)\n- Given millions to charity\n- Started my own snack company Feastables\n- Started my own software company Viewstats\n- Gave away a private island (twice)\n- Gave away 1 million meals\n- I counted to 100k\n- Ran a marathon in the world's largest shoes\n- Survived 50 hours in Antarctica\n- Recreated Squid Game in real life\n- Created the largest competition show with 1000 people (Beast Games)\n- Gave $5,000,000 to one person\n\nTerms & Conditions of Current Sweepstakes: \nhttps://mrb.gg/bow-and-arrow\nhttps://bit.ly/MrB_Birthday_YT\nhttps://bit.ly/MrB_Cash_Giveaway\n\n\n",
"verified": null,
"followers": 508000000,
"following": null,
"posts_count": 993,
"likes_count": null,
"url": "https://www.youtube.com/channel/UCX6OQ3DkcsbYNE6H8uQQuVA",
"private": null,
"joined_at": "2012-02-20",
"ext": {
"country": "US",
"keywords": "mrbeast6000 beast mrbeast Mr.Beast mr",
"topicCategories": [
"https://en.wikipedia.org/wiki/Entertainment",
"https://en.wikipedia.org/wiki/Lifestyle_(sociology)"
],
"bannerExternalUrl": "https://yt3.googleusercontent.com/mHMO_eEMp0dPvh0ADwXhPXNYb_GnjSVsLI8biqF1CpxT8OPl7izhNQsDPD3JHhd5y5Mg9GrP",
"madeForKids": false,
"hiddenSubscriberCount": false,
"related_playlists": {
"likes": "",
"uploads": "UUX6OQ3DkcsbYNE6H8uQQuVA"
},
"topic_ids": [
"/m/02jjt",
"/m/019_rr"
],
"unsubscribed_trailer": "iYlODtkyw_I"
}
},
"computed": {
"engagement_rate": null,
"language": "en",
"content_category": "gaming",
"estimated_reach": null
}
},
"credits_used": 1,
"credits_remaining": 9999,
"request_id": "req_example000000",
"cached": false
}Prefer another language?
FAQ
Have a question? We got answers
Find answers to frequently asked questions about SocialCrawl's API, pricing, and capabilities.
Contact usDo I need a YouTube developer account to scrape YouTube channels?
No. SocialCrawl handles authentication and proxies upstream, so you never register a YouTube app, manage OAuth tokens, or run your own scrapers. One API key returns YouTube data directly.
What does the YouTube Channel endpoint return?
It returns a channel's subscriber count, total views, video count, description, country, and thumbnails by handle, channel id, or URL. The response is normalized into SocialCrawl's unified schema, identical in shape across every platform.
How much does it cost to scrape YouTube channels?
Each call costs a small number of credits, and new accounts start with free credits. There are no monthly minimums, so you pay only for the calls you make.
Can I use this cURL code in production?
Yes. The snippet on this page is the real request against the live API. For production, add error handling and follow the response cursor to paginate through large result sets.
Ask AI about SocialCrawl
