How to get YouTube video comments with Python

Pass the video ID and page with data.next, 20 comments a page. Ten pages are 200 comments for 10 calls and $0.02, with no Google Cloud project, OAuth or daily quota units.

Updated 2026-11-22·This page as Markdown

Page through the comments

id is the value after v= in a youtube.com link, or the part after youtu.be/. The next-page token is long; it arrives in data.next and goes back unchanged.

YouTube comments API·GET /v1/youtube/comments/list·$0.002 a call

curl "https://xtikapi.com/v1/youtube/comments/list?id=CLsCU_JX1eU" \
  -H "Authorization: Bearer YOUR_API_KEY"
Recorded response (lists keep the first two items)
{
  "data": {
    "items": [
      {
        "id": "xxxxxxxx035xxx8xx2x0xxxxxx",
        "text": "Example text",
        "author": {
          "id": "xx_xxxxxxxxxxxxxxx5x99xx",
          "name": "Example name",
          "avatar": "https://example.com/image.jpg"
        },
        "likeCount": 60,
        "replyCount": 14
      },
      {
        "id": "xxxx2xxxxxxxxxxx9x40xxxxxx",
        "text": "Example text",
        "author": {
          "id": "xxxxxxxxx8xx7xx3xxxxxxxx",
          "name": "Example name",
          "avatar": "https://example.com/image.jpg"
        },
        "likeCount": 1530,
        "replyCount": 79
      }
    ],
    "has_more": true,
    "next": {
      "cursor": "Eg0SC0NMc0NV…"
    }
  },
  "meta": {
    "request_id": "example",
    "endpoint": "youtube.comments.list",
    "normalized": true,
    "unavailable": [
      "createdAt"
    ],
    "billing": {
      "charged": true,
      "amount": 0.002,
      "balance": 4.98
    }
  }
}

What the example costs

Calls: 10
Price: $0.002
Subtotal: $0.02
Total
Calls: 10
Price: —
Subtotal: $0.02

Failed calls and timeouts are not charged. A new account with a verified email gets $0.50 of trial balance, enough to run this example.

Good to know

  • A page held 20 comments in our test on 2026-11-22, and page two had no overlap.
  • Pass sort_by to switch between top comments and newest first.
  • Replies are separate: youtube.comment_replies.list.
  • The YouTube Data API v3 charges 1 quota unit per commentThreads page out of 10,000 a day; here there is no quota, only the per-call price.

Endpoints

More about YouTube

Questions

How much does this cost with XTikAPI?

The example here is 10 calls, $0.02 in total. Failed calls and timeouts are free, and a new account with a verified email gets $0.50 of trial balance.

Is this the official YouTube Data API?

No. It reads the public comments shown on the video page, so it needs no Google API key or quota; the response uses the same comment shape as every other platform here.