# YouTube Comments Scraper – Comment Search, Downloader & API (`rowfeed/youtube-comments-scraper`) Actor

The top comments of any YouTube video as clean rows: text, likes, replies and date, plus the video's title and total comment count. Bulk up to 1,000 videos, 700 comments each. No author names. Licensed data, no blocked runs. $0.20 per 1,000 comments.

- **URL**: https://apify.com/rowfeed/youtube-comments-scraper.md
- **Developed by:** [Rowfeed](https://apify.com/rowfeed) (community)
- **Categories:** Videos, Social media, AI
- **Features:** Limited permissions
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $0.20 / 1,000 comments

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.

Learn more: https://docs.apify.com/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

## YouTube Comments Scraper – Comment Search, Downloader & API

Get the top comments of any YouTube video as clean rows: the comment text, likes, number of replies and date, with the video's title and total comment count. Paste one video or 1,000, and get up to 700 comments from each.

Built for audience and market research, product feedback and complaint mining, content ideas from what viewers ask, sentiment analysis, AI training and RAG data, and AI agents that need to know what people say under a video.

The data comes through a licensed data provider (DataForSEO), not by scraping YouTube from a browser, so runs do not fail on captchas or blocks.

### What you get

- **Top comments in YouTube's order**, up to 700 per video.
- **Text, likes, replies and date** on every row, plus the video title, link and total comment count.
- **Bulk:** links in any format (watch, youtu.be, Shorts, live, embed) or bare video ids. Duplicates are looked up once.
- **Privacy by default:** no author by default. Turn on `includeAuthor` to add the commenter's public YouTube `@handle` (handy for replying or spotting repeat commenters). Names, pictures, channel links and emails are never included, and `@handles` and email addresses inside the text become `[user]` and `[email removed]`.

### Example output row

A real comment from the pre-filled video:

```json
{
  "video_id": "dQw4w9WgXcQ",
  "video_url": "https://www.youtube.com/watch?v=dQw4w9WgXcQ",
  "video_title": "Rick Astley - Never Gonna Give You Up (Official Video) (4K Remaster)",
  "position": 1,
  "text": "My algebra teacher said that this was a link to the test answers",
  "likes": 71000,
  "replies": 688,
  "published": "2019-11-12T06:44:00Z",
  "published_ago": "7 years ago",
  "video_comments_total": 2462033
}
```

### How to use

1. Click **Try for free** (or **Start**) at the top of this page to open the input form.
2. Fill in **YouTube videos**. Video links (watch, youtu.be, Shorts, live, embed) or 11-character video ids. The form comes with a working example, so you can also run it as it is.
3. Optional: adjust **Max comments per video**, **Include the commenter's @handle**. Every field has a sensible default.
4. Click **Start** and wait for the run to finish.
5. Download the results as Excel, CSV or JSON from the **Output** tab, or get them through the Apify API, a schedule or an integration (Make, Zapier, Google Sheets ...).

### Pricing

Pay per event, no subscription:

- **$0.20 per 1,000 comments** ($0.0002 per comment).
- $0.001 per video looked up (also when it has no comments).
- $0.002 per run start.

Examples: 100 comments from one video cost $0.023. 10 videos × 700 comments cost $1.41. Invalid links are never charged. The pre-filled example is served from a saved lookup and costs only the start fee.

### Input

| Field | What it does |
|---|---|
| `videos` | Video links or ids, one per line, up to 1,000. |
| `maxCommentsPerVideo` | Up to 700 (default 100). |
| `includeAuthor` | Add the commenter's public `@handle` (off by default). |

### Good to know

- **Top comments, not replies:** you get YouTube's top-level comments in its own order. The `replies` field counts the replies under each.
- **Dates are approximate** for older comments: YouTube shows "7 years ago", and `published` is worked out from that. `published_ago` is what YouTube shows.
- **Live lookups need a paid Apify plan** (any plan); the pre-filled example works on the free plan.
- **The `@handle` is personal data** in many countries. Use it lawfully (for example under GDPR); you are responsible for how you use the data.
- Not affiliated with YouTube or Google.

### More tools from Rowfeed

- [YouTube Transcript API](https://apify.com/rowfeed/youtube-transcript-api) – the full transcript of any video as text, with timestamps.
- [YouTube Search API](https://apify.com/rowfeed/youtube-search-api) – YouTube search results for any keyword, with views and channels.
- [Reddit Scraper](https://apify.com/rowfeed/reddit-scraper) – posts and newest comments of any subreddit, filtered by your keywords.
- [Google Sheets Export](https://apify.com/rowfeed/google-sheets-export) – send the results of any run to a Google Sheet.

# Actor input Schema

## `videos` (type: `array`):

Video links (watch, youtu.be, Shorts, live, embed) or 11-character video ids. Up to 1,000 per run.

## `maxCommentsPerVideo` (type: `integer`):

Top comments in YouTube's order, up to 700 per video.

## `includeAuthor` (type: `boolean`):

Off by default. On = add the commenter's public YouTube @handle. Never their name, picture, channel link or email. You are responsible for using it lawfully (e.g. GDPR).

## Actor input object example

```json
{
  "videos": [
    "https://www.youtube.com/watch?v=dQw4w9WgXcQ",
    "https://youtu.be/jNQXAC9IVRw",
    "https://www.youtube.com/shorts/xxxxxxxxxxx"
  ],
  "maxCommentsPerVideo": 100,
  "includeAuthor": false
}
```

# Actor output Schema

## `results` (type: `string`):

No description

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "videos": [
        "https://www.youtube.com/watch?v=dQw4w9WgXcQ"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("rowfeed/youtube-comments-scraper").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = { "videos": ["https://www.youtube.com/watch?v=dQw4w9WgXcQ"] }

# Run the Actor and wait for it to finish
run = client.actor("rowfeed/youtube-comments-scraper").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "videos": [
    "https://www.youtube.com/watch?v=dQw4w9WgXcQ"
  ]
}' |
apify call rowfeed/youtube-comments-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,rowfeed/youtube-comments-scraper"
        }
    }
}
```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/Ikuq9Duoo9RhxYd8S/builds/hhQwqs3EaOPluuJ8C/openapi.json
