# YouTube Community Posts Scraper — Polls, Images & Comments (`memo23/youtube-community-posts-scraper`) Actor

Scrape YouTube community posts from any channel with no login or API key: post text, likes, comment counts, images, poll choices with total votes, linked videos. Add the comments and replies under each post. Give a channel handle, link or id, or paste post links.

- **URL**: https://apify.com/memo23/youtube-community-posts-scraper.md
- **Developed by:** [Muhamed Didovic](https://apify.com/memo23) (community)
- **Categories:** Social media, Videos
- **Stats:** 2 total users, 2 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $3.00 / 1,000 community posts

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 Community Posts Scraper — Polls, Images & Comments

Get the **community tab** ("Posts") of any YouTube channel as structured data, without an account or an API key: post text, likes, comment counts, images, polls with their choices and total votes, linked videos, and on request the comments and replies under each post.

### What it does

| Input | You get | Row type |
|-------|---------|----------|
| Channel handle, link or id | One summary row for the channel, then its community posts, newest first | `channel`, `post` |
| Community post link or id | That post in full | `post` |
| `includeComments` | The comments under every post in the run | `comment` |
| `includeReplies` | The replies under each comment that has at least 3 | `reply` |

The dataset has **Posts** and **Comments** views.

### How It Works

<p align="center">
  <img src="https://api.apify.com/v2/key-value-stores/YHsdD3Cztp9P4Lzde/records/how-it-works-youtube-community.png" alt="How the YouTube community posts scraper works" width="900" />
</p>

### Why this one

- **No login, no API key, no proxy.** The official YouTube Data API has no endpoint for community posts at all.
- **Every kind of post.** Text, single image, image gallery, poll, shared video.
- **Polls as data.** The choices and the total number of votes.
- **Comments and replies.** Each reply points at its parent comment, and creator replies are flagged.
- **Any way of naming a channel.** `@handle`, a channel link, or a `UC…` channel id.

### Input

| Field | Type | Description |
|-------|------|-------------|
| `channels` | `string[]` | Handles (`@MrBeast`, `MrBeast`), channel links or channel ids. |
| `maxPostsPerChannel` | integer | Newest posts per channel. Default 20, minimum 5. |
| `postUrls` | `string[]` | Post links (`https://www.youtube.com/post/Ugkx…`) or post ids. |
| `includeComments` / `maxCommentsPerPost` | boolean / integer | Comment rows for every post in the run. Default 40 per post. |
| `includeReplies` / `maxRepliesPerComment` | boolean / integer | Reply rows. Default 10 per comment. |
| `language` / `country` | string | Language of YouTube's own texts such as "2 days ago" (default `en`), and the country asked from (default `US`). |
| `maxItems` | integer | Cap on post rows per run. Default 1,000. |

#### Example: a channel's latest posts

```json
{
  "channels": ["@MrBeast", "https://www.youtube.com/@mkbhd"],
  "maxPostsPerChannel": 30
}
```

#### Example: posts with comments and replies

```json
{
  "channels": ["@MrBeast"],
  "maxPostsPerChannel": 10,
  "includeComments": true,
  "maxCommentsPerPost": 100,
  "includeReplies": true
}
```

#### Example: one post in full

```json
{
  "postUrls": ["https://www.youtube.com/post/UgkxZusu9I1Z-VuU5PGZNA2gclHi8V9CJVZk"],
  "includeComments": true,
  "maxCommentsPerPost": 500
}
```

### Output

Post:

```json
{
  "type": "post",
  "postId": "UgkxZusu9I1Z-VuU5PGZNA2gclHi8V9CJVZk",
  "url": "https://www.youtube.com/post/UgkxZusu9I1Z-VuU5PGZNA2gclHi8V9CJVZk",
  "text": "Would you rather stop aging for 100 years or receive 1 billion dollars right now?",
  "publishedText": "2 months ago",
  "likes": 104000,
  "likesText": "104K",
  "comments": 10000,
  "commentsText": "10K",
  "attachmentType": "poll",
  "images": [],
  "pollChoices": [
    { "text": "100 Years Of No Aging", "votes": null, "percentage": null },
    { "text": "1 Billion Dollars", "votes": null, "percentage": null }
  ],
  "pollTotalVotes": 1800000,
  "videoUrl": null,
  "channelId": "UCX6OQ3DkcsbYNE6H8uQQuVA",
  "channelName": "MrBeast",
  "channelUrl": "https://www.youtube.com/@MrBeast",
  "source": "channel"
}
```

`attachmentType` is `none`, `image`, `multi_image`, `poll` or `video`. Image posts carry `images[]` at the largest size; a shared video carries `videoId`, `videoTitle` and `videoUrl`.

Comment:

```json
{
  "type": "comment",
  "commentId": "UgzaP-TSF3uoXlMuJHh4AaABAg",
  "postId": "UgkxHIfkQ3K2my65-kPq4VkRv9KrBRyN7alx",
  "postUrl": "https://www.youtube.com/post/UgkxHIfkQ3K2my65-kPq4VkRv9KrBRyN7alx",
  "parentCommentId": null,
  "text": "“Juan and the gang” is a peak name.",
  "publishedText": "12 days ago",
  "likes": 7200,
  "replyCount": 36,
  "authorName": "@Nexxasvr",
  "authorChannelId": "UCSJGbr-KeIRZBzJZyopKhbQ",
  "authorUrl": "https://www.youtube.com/@Nexxasvr",
  "authorIsCreator": false
}
```

A `reply` row has the same fields with `parentCommentId` set. A `channel` row has `channelId`, `channelName`, `channelUrl`, `communityUrl` and `hasCommunityPosts`.

### Pricing

Pay per event. You pay for rows you receive; a channel or post that is not found costs nothing.

| Event | When | Price |
|-------|------|-------|
| Actor start | Once per run | $0.005 |
| Channel | Each channel found, with or without posts | $0.005 |
| Post | Each community post | $0.003 |
| Comment | Each comment or reply row | $0.0015 |

1,000 posts cost $3; 1,000 comments cost $1.50. Set a maximum cost per run in the run options and the Actor stops there with what it has.

### FAQ

**Do I need a YouTube account, an API key or a proxy?**
No.

**Why are dates texts like "2 months ago"?**
YouTube shows community posts and their comments with relative dates only, so that is what exists. Counts come both as YouTube prints them (`likesText`: "104K") and as a number (`likes`: 104000).

**Why are a poll's per-choice votes empty?**
YouTube shows the split only to signed-in viewers who have voted. The choices and the total number of votes are always returned.

**Why did I get 10 posts when I asked for 12?**
Posts arrive in pages of 10. A further page is read only when at least 5 more are wanted, so small remainders are dropped.

**Why do some posts have no comment rows?**
Comments are read for posts with at least 5 comments, and replies for comments with at least 3 replies.

**The channel row says `hasCommunityPosts: false`.**
The channel exists but has never posted on its community tab, or has removed its posts.

### 🤖 For AI Agents & LLM Apps

**Purpose:** YouTube community posts, their polls and images, comments and replies as structured JSON, with no login or API key.

**Minimal input:** `{"channels": ["@MrBeast"], "maxPostsPerChannel": 10}`

**Output:** rows with `type` = `channel` | `post` | `comment` | `reply`. Posts: postId, url, text, publishedText, likes, comments, attachmentType, images, pollChoices, pollTotalVotes, videoUrl, channelId, channelName. Comments: commentId, postId, parentCommentId, text, likes, replyCount, authorName, authorChannelId, authorIsCreator.

**Behaviors to know:** `maxItems` caps post rows only. Per-source minimums are 5. Dates are relative texts. Free-plan runs return up to 100 posts.

### ⚠️ Disclaimer

This Actor collects publicly available data only. It is not affiliated with, endorsed by, or sponsored by YouTube or Google LLC. You are responsible for using the data in line with applicable laws and YouTube's terms, including rules on personal data.

### SEO Keywords

youtube community posts scraper, youtube community tab scraper, youtube posts scraper, youtube polls scraper, youtube post comments scraper, youtube community comments, youtube channel posts api, youtube community api alternative, youtube poll results, youtube creator posts, youtube community monitoring, youtube post images, youtube data export

# Actor input Schema

## `channels` (type: `array`):

Channels whose community posts you want. Any of these work: a handle (@MrBeast or MrBeast), a channel link (https://www.youtube.com/@MrBeast), or a channel id (UC...). You get one summary row per channel and then its posts, newest first.

## `maxPostsPerChannel` (type: `integer`):

How many of the newest posts to return for each channel. A page holds 10 posts.

## `postUrls` (type: `array`):

Links to single community posts (https://www.youtube.com/post/Ugkx...) or bare post ids.

## `includeComments` (type: `boolean`):

Also return the comments under each post, one row per comment. Posts with fewer than 5 comments are skipped.

## `maxCommentsPerPost` (type: `integer`):

Upper limit of top-level comments for each post. A page holds 20 comments.

## `includeReplies` (type: `boolean`):

Also return the replies under each comment that has at least 3 of them. Needs comments turned on.

## `maxRepliesPerComment` (type: `integer`):

Upper limit of replies returned for one comment.

## `language` (type: `string`):

Language of the texts YouTube writes itself, such as "2 days ago". Two letters, for example en, de, es, ja.

## `country` (type: `string`):

Two-letter country code YouTube is asked from, for example US, GB, DE.

## `maxItems` (type: `integer`):

The run stops collecting posts when it reaches this number, across all channels and links. Comments do not count toward it.

## Actor input object example

```json
{
  "channels": [
    "@MrBeast"
  ],
  "maxPostsPerChannel": 20,
  "includeComments": false,
  "maxCommentsPerPost": 40,
  "includeReplies": false,
  "maxRepliesPerComment": 10,
  "language": "en",
  "country": "US",
  "maxItems": 1000
}
```

# Actor output Schema

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

Rows told apart by `type`: `channel`, `post`, `comment` and `reply`.

# 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 = {
    "channels": [
        "@MrBeast"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("memo23/youtube-community-posts-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 = { "channels": ["@MrBeast"] }

# Run the Actor and wait for it to finish
run = client.actor("memo23/youtube-community-posts-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 '{
  "channels": [
    "@MrBeast"
  ]
}' |
apify call memo23/youtube-community-posts-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,memo23/youtube-community-posts-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/7KzrlkpWiXAJVvUSf/builds/jWtgJ9qaCUwN41odA/openapi.json
