# How do I get a YouTube channel ID from an @handle?

Use the Data API's `channels.list` with `forHandle=@name` (the @ is optional): it returns the channel whose `id` starts with `UC`, costs 1 quota unit, and can't be combined with `id`, `forUsername` or other filters in one request. Old `forUsername` only works for legacy usernames, which is why so many Stack Overflow answers fail on handles. With XTikAPI, `youtube.accounts.search` finds the channel by keyword and `youtube.accounts.detail` reads it by `channel_id`, $0.002 a call.

Updated 2026-11-21

## Which lookup to use

| You have | Official call | Note |
| --- | --- | --- |
| `@GoogleDevelopers` | `channels.list?part=id,snippet&forHandle=@GoogleDevelopers` | 1 quota unit |
| A legacy username | `channels.list?forUsername=...` | Fails for handle-only channels |
| A video ID | `videos.list`, read `snippet.channelId` | 1 unit |
| A channel URL `/channel/UC...` | Nothing to look up | The ID is in the URL |

Setting two filters at once returns `400 invalidCriteria`.

## With XTikAPI

1. `youtube.accounts.search` with `keyword` (the handle or channel name) returns matching channels with their IDs.
2. `youtube.accounts.detail` with `channel_id` returns the channel's title, description and counts.
3. `youtube.videos.list` with the same `channel_id` lists its uploads.

Cost: resolving and reading 500 channels = 1,000 calls × $0.002 = $2.

## Why XTikAPI

- XTikAPI reads YouTube with 12 endpoints from $0.002 a call, and a failed call is not charged.
- Fewer tokens for AI: across 11 recorded live YouTube calls (2026-11-18), raw platform JSON is ~52k tokens vs ~12k via XTikAPI REST (77.4% fewer) and ~13k via MCP (75.8% fewer).
- See before you pay: 192 of 229 endpoints show a recorded real response on their page (11 of 12 for YouTube).
- One shape: posts, comments and accounts from 19 platforms come back as the same objects, author in author and counts in metrics, so another platform needs no new parser.
- Free trial: a verified account gets $0.50, no card.

## Endpoints

- [YouTube channel search API](https://xtikapi.com/apis/youtube/accounts/search) ($0.002 a call): Search YouTube channels by keyword.
- [YouTube channel details API](https://xtikapi.com/apis/youtube/accounts/detail) ($0.002 a call): A YouTube channel profile.
- [YouTube video list API](https://xtikapi.com/apis/youtube/videos/list) ($0.002 a call): A YouTube channel's videos.

## More about YouTube

- [YouTube API](https://xtikapi.com/apis/youtube)
- [yt-dlp YouTube errors ("confirm you're not a bot", incomplete comments): how do I get video data?](https://xtikapi.com/answers/yt-dlp-sign-in-to-confirm-not-a-bot)
- [How do I list only a channel's Shorts with the YouTube API?](https://xtikapi.com/answers/youtube-api-list-channel-shorts)
- [How do I get around the YouTube Data API's 10,000-unit daily quota?](https://xtikapi.com/answers/youtube-api-quota-alternative)
- [Why does YouTube commentThreads.list return 403 commentsDisabled?](https://xtikapi.com/answers/youtube-api-comments-disabled-403)

## Sources

What this page says about other products comes from their own pages and docs, read on 2026-11-21.

- [YouTube Data API: Channels: list (forHandle)](https://developers.google.com/youtube/v3/docs/channels/list)
- [Stack Overflow: How to map YouTube handles to channel IDs](https://stackoverflow.com/questions/74323173)
- [Stack Overflow: How to retrieve a channel ID from a channel name or URL](https://stackoverflow.com/questions/13572657)

## Questions

### Is a handle the same as the old custom URL?

No. Handles start with @ and are looked up with `forHandle`; legacy usernames use `forUsername`. A channel can have one, both or neither.

---

XTikAPI: one API key for public social media data, prepaid per call. [HTML version](https://xtikapi.com/answers/youtube-handle-to-channel-id) · [llms.txt](https://xtikapi.com/llms.txt) · [OpenAPI](https://xtikapi.com/openapi.json)
