Skip to content
youtubeapi.io
Audience Intelligence · Tutorial6 min read·Updated 2026-11-04

Extracting YouTube Video Comments & Audience Sentiment for AI Analysis

How to ingest thousands of YouTube video comments sorted by top engagement or newest timestamp for product feedback mining, creator sponsorship diligence, and LLM sentiment clustering.

$0.20 / 1K Videos · $0.10 / 1K Comments & Followers · No OAuth Needed

Instant Quickstart · Copy & Run in 30 Seconds

Fetch top comments for a YouTube video

Execute in Live Playground →
import requests

res = requests.get(
    "https://api.youtubeapi.io/v1/youtube/comments",
    params={"video_id": "dQw4w9WgXcQ", "sort_by": "top", "limit": 50},
    headers={"x-api-key": "yt_live_your_api_key"},
)
comments = res.json()["data"]["items"]

Key Engineering Takeaways (TL;DR)

  • ✓GET /v1/youtube/comments extracts up to 100 comments per call sorted by top or newest.
  • ✓Includes comment_id, author_name, author_channel_id, like_count, reply_count, is_hearted, and is_pinned.
  • ✓Costs 1 Credit per returned comment ($0.10 per 1,000 comments base rate, minimum 10 Credits per non-empty call).

1. Fetching Top Comments & Paginating with next_cursor

Every response returns a next_cursor token when additional comment pages exist.

Fetch top comments for a YouTube video

Pass either an 11-char video_id or full youtube.com watch URL.

curl "https://api.youtubeapi.io/v1/youtube/comments?video_id=dQw4w9WgXcQ&sort_by=top&limit=50" \
  -H "x-api-key: yt_live_your_api_key"

Interactive Engineering Workbench · GET /v1/youtube/comments

Verify real-time latency, pagination math & JSON schema

5,000 videos/day
10,000 comments/day
20,000 followers/day
Our HTTP Calls/Day
452
Large page sizes
Legacy Provider Calls
1,334
30-item small pages
Official Research API
Within 1K Cap
1,000 req/day limit
Estimated Monthly Pipeline Cost (30 Days)
$72.73/ mo with Business bonus ($120.00 base rate)
Daily consumption: 40,000 Credits ($4.00/day)
YouTubeAPI.io (with volume bonus):$72.73 / mo
Legacy Scrapers ($1.50 / 1K calls):$60.03 / mo
Failed / 404 request fee:$0.00 (0 Credits)

Frequently Asked Questions

What happens if comments are turned off on a YouTube video?
The endpoint returns an empty items[] array and charges 0 Credits.