YouTube Comments Scraper avatar

YouTube Comments Scraper

Pricing

$0.80 / 1,000 comments

Go to Apify Store
YouTube Comments Scraper

YouTube Comments Scraper

Scrape comments and replies from any YouTube video or Short: text, author, likes, reply counts, dates, pinned and hearted flags. Top or newest first, bulk input, JSON/CSV/Excel export. Pay only per comment delivered.

Pricing

$0.80 / 1,000 comments

Rating

0.0

(0)

Developer

Imad

Imad

Maintained by Community

Actor stats

1

Bookmarked

2

Total users

1

Monthly active users

4 days ago

Last modified

Share

Scrape all comments and replies from any YouTube video or Short — text, author, likes, reply counts, dates, pinned and hearted flags — and export them to JSON, CSV or Excel in minutes. Paste video URLs, choose Top comments or Newest first, and pay only for the comments you actually get. No YouTube API key, no login, no quota.

What does YouTube Comments Scraper do?

YouTube Comments Scraper reads the comment section of the videos you give it — the same comments you see on youtube.com — and turns every comment (and, optionally, every reply) into a clean dataset row. It is built for audience research, sentiment analysis, product feedback mining, creator analytics, academic datasets and AI pipelines.

  • 💬 Comments and replies — each reply is its own row, placed right after its parent comment and linked by parentCommentId.
  • 🔀 Top or Newest — YouTube's own Top comments ranking or Newest first, exactly like the sort menu on YouTube.
  • 📌 Rich flags — pinned comments, comments hearted by the creator, comments written by the channel owner, verified authors, edited comments.
  • 📦 Bulk input — many videos and Shorts per run, processed in parallel; duplicates are removed automatically.
  • 🎯 Precise limits — cap comments per video and replies per comment, or scrape everything.
  • 💸 Fair pricing — videos with comments turned off, unavailable videos and invalid links are reported in an error row and never charged.
  • 🤖 API- and agent-ready — stable JSON schema, callable from the Apify API, Python/JavaScript clients, Make, Zapier, n8n or AI agents via Apify's MCP server.

What data can you extract from YouTube comments?

FieldDescription
typecomment, reply, or error (a video that returned no comments — never charged)
videoId, videoTitle, videoUrlThe video the comment belongs to
commentId, parentCommentId, isReplyComment ID; replies carry the ID of their parent comment
positionRank in the chosen sort order (for replies: rank within the thread)
textFull comment text, including emojis and line breaks
author, authorChannelId, authorUrl, authorAvatarCommenter's handle, channel ID, channel link and avatar
authorIsVerified, isAuthorChannelOwnerVerified badge; comment written by the video's own channel
isPinned, isHearted, isEditedPinned by the creator, hearted by the creator, edited by its author
likeCount, replyCountLikes and number of replies
publishedTime, publishedAtEstimateYouTube's relative time ("3 days ago") and an approximate ISO date
commentUrlDirect link that opens the video with this comment highlighted
totalCommentCountTotal comments YouTube shows for the video (replies included)
sortBy, scrapedAtSort order used and scrape timestamp
errorWhy a video returned no comments (null on comment rows)

How to scrape YouTube comments — step by step

  1. Click Try for free (a free Apify account takes a minute).
  2. Paste one or more YouTube video URLs or IDs — watch links, youtu.be links, Shorts, embeds and bare IDs all work.
  3. Set Max comments per video (0 = all comments) and choose Top comments or Newest first.
  4. Tick Include replies if you want reply threads too, optionally capped with Max replies per comment.
  5. Click Start. Results stream into the Dataset tab while the run is going.
  6. Export them as CSV, Excel, JSON, XML or HTML, or fetch them through the API.

How much does it cost to scrape YouTube comments?

$0.80 per 1,000 comments — $0.0008 per comment or reply delivered. Nothing else: no start fee, no charge for videos without comments.

  • 100 comments from each of 10 videos → 1,000 comments → $0.80
  • Every comment and reply of a popular tutorial with 9,421 comments → about $7.50
  • Apify's free plan includes $5 of monthly usage, enough for about 6,000 comments a month at no cost.

Set Maximum cost per run in the run options to cap spending: the actor stops cleanly as soon as the limit is reached and keeps everything scraped so far.

Input example

{
"videoUrls": [
"https://www.youtube.com/watch?v=LKrwhjOI8Nc",
"https://youtu.be/aircAruvnKk",
"https://www.youtube.com/shorts/4z8Hi_uQOkE"
],
"maxComments": 500,
"sortBy": "top",
"includeReplies": true,
"maxRepliesPerComment": 20
}

Output example

A pinned comment written by the channel owner, followed by one of its replies:

[
{
"type": "comment",
"videoId": "LKrwhjOI8Nc",
"videoTitle": "There's never been a better time to go into math",
"videoUrl": "https://www.youtube.com/watch?v=LKrwhjOI8Nc",
"commentId": "UgyrAqOygKV6crh2jnp4AaABAg",
"parentCommentId": null,
"isReply": false,
"position": 1,
"text": "Looking back at this, there's one thing I allude to at the end, but wish I had included more in the middle …",
"author": "@3blue1brown",
"authorChannelId": "UCYO_jab_esuFRV4b17AJtAw",
"authorUrl": "https://www.youtube.com/channel/UCYO_jab_esuFRV4b17AJtAw",
"authorAvatar": "https://yt3.ggpht.com/ytc/AIdro_nFzZFPLxPZRHcE3SSwzdrbuWqfoWYwLAu0_2iO6blQYAU=s88-c-k-c0x00ffffff-no-rj",
"authorIsVerified": true,
"isAuthorChannelOwner": true,
"isPinned": true,
"isHearted": false,
"isEdited": false,
"likeCount": 512,
"replyCount": 52,
"publishedTime": "3 days ago",
"publishedAtEstimate": "2026-10-18",
"commentUrl": "https://www.youtube.com/watch?v=LKrwhjOI8Nc&lc=UgyrAqOygKV6crh2jnp4AaABAg",
"totalCommentCount": 5039,
"sortBy": "top",
"scrapedAt": "2026-10-21T03:06:21+00:00",
"error": null
},
{
"type": "reply",
"videoId": "LKrwhjOI8Nc",
"commentId": "UgyrAqOygKV6crh2jnp4AaABAg.Ac3_WPGoUWZAc3aAHs2BVd",
"parentCommentId": "UgyrAqOygKV6crh2jnp4AaABAg",
"isReply": true,
"position": 1,
"text": "I would like to ask you though, I think you're passionate about math, but how much joy do you feel when doing math? …",
"likeCount": 8,
"replyCount": 0,
"isEdited": true,
"publishedTime": "3 days ago",
"…": "same video and author fields as above"
}
]

A video that returns nothing gets one uncharged row, for example { "type": "error", "videoId": "XqZsoesa55w", "error": "Comments are turned off for this video" }.

How to export YouTube comments to CSV or Excel

Open the run's Dataset tab and click Export: CSV, Excel (XLSX), JSON, JSONL, XML and HTML are available, with an option to pick columns. For spreadsheets, the Overview view gives a compact table (video, author, comment, likes, replies, date, flags, link). Through the API, add ?format=csv or ?format=xlsx to the dataset items URL.

Use the API from Python, JavaScript or no-code tools

from apify_client import ApifyClient
client = ApifyClient("<YOUR_APIFY_TOKEN>")
run = client.actor("damilo/youtube-comments-apify").call(
run_input={"videoUrls": ["https://www.youtube.com/watch?v=aircAruvnKk"], "maxComments": 500}
)
for comment in client.dataset(run["defaultDatasetId"]).iterate_items():
print(comment["likeCount"], comment["author"], comment["text"][:80])

The actor also works from Make, Zapier, n8n, Google Sheets and webhooks, and as a tool for AI agents (Claude, ChatGPT, LangChain, LlamaIndex) through Apify's MCP server — agents get structured comments with explicit error rows instead of guesses.

What can you do with YouTube comments data?

  • Sentiment analysis and audience research — what viewers love, hate and ask for, at scale.
  • Product and market feedback — mine reviews, unboxings and competitor videos for feature requests and complaints.
  • Creator and channel analytics — engagement per video, top commenters, pinned and hearted comments, creator replies.
  • Content ideas and SEO — recurring questions in comments are ready-made topics for your next video or article.
  • Moderation and brand safety — monitor comment sections of your own or sponsored videos.
  • Research and AI datasets — conversation data with reply structure for NLP, classification and LLM evaluation.

Pair it with the YouTube Transcript Scraper

Comments tell you how people react; the transcript tells you what was said. Combine this actor with the YouTube Transcript Scraper to give an LLM the full context of a video — the talk and the audience's response — for summaries, Q&A or content repurposing.

FAQ

Can I scrape all comments of a YouTube video?

Yes — set Max comments per video to 0. Very popular videos have millions of comments; the actor streams them page by page, so use a limit or the run's maximum cost if you only need a sample. The video's total is in totalCommentCount.

Does it scrape replies?

Yes. Tick Include replies. Each reply becomes its own row (type: "reply") right after its parent, with parentCommentId linking them. Use Max replies per comment to cap long threads.

Does it work with YouTube Shorts and live streams?

Shorts — yes, paste the Shorts URL. Live chat is not part of the comment section, so live streams that have comments disabled return an error row; finished premieres and uploads work normally.

Why are like counts rounded?

YouTube displays likes above 1,000 in rounded form (for example "13K"), and that is the only figure it publishes, so likeCount is 13000 for such comments. Counts below 1,000 are exact.

How accurate are comment dates?

YouTube only shows relative times such as "3 weeks ago". publishedTime keeps that text, and publishedAtEstimate converts it into an approximate ISO date (exact to the day for recent comments, within a month or so for comments that are years old).

Do I need a YouTube API key, an account or cookies?

No. The actor reads the same public data a logged-out visitor sees on youtube.com — no Google Cloud project, no YouTube Data API quota, no login.

Why did a video return no comments?

The error row says why: comments turned off (common on videos made for kids), no comments yet, video unavailable or private, or not a valid YouTube link. These rows are never charged.

Comments are publicly visible data, and this actor only reads what YouTube shows to any visitor. Comments can still contain personal data, so make sure your use complies with privacy laws such as GDPR and with YouTube's terms of service, and do not republish personal data without a lawful basis.

More data tools by damilo

Support

Need channel-wide scraping, comment search or a custom export? Open the Issues tab — it is answered quickly. If the actor saved you time, a ⭐⭐⭐⭐⭐ review helps other people find it.