YouTube Channel ID Extractor Pro
Pricing
$7.00/month + usage
Go to Apify Store

YouTube Channel ID Extractor Pro
This Apify Actor extracts YouTube channel IDs from multiple channel URL formats (direct /channel/, @username, /c/, and /user/). It intelligently resolves non-direct URLs using yt-dlpvalidates inputs, processes multiple URLs, and outputs results with success/failure status to the Apify Dataset along
Pricing
$7.00/month + usage
Rating
0.0
(0)
Developer

Data Pilot
Maintained by Community
Actor stats
0
Bookmarked
2
Total users
1
Monthly active users
5 days ago
Last modified
Share
YouTube Channel ID Extractor
A powerful Apify Actor that extracts YouTube channel IDs from various URL formats including direct channel links, @usernames, custom URLs, and legacy user URLs. Uses yt-dlp for reliable channel resolution.
π― Features
- π Multiple URL Formats - Supports all YouTube channel URL types
- π― Direct Extraction - Instant extraction from channel/ID URLs
- π Username Resolution - Resolves @username to channel ID
- π Custom URL Support - Handles youtube.com/c/customname
- π€ User URL Support - Processes youtube.com/user/username
- π Batch Processing - Extract multiple channel IDs at once
- β Error Handling - Graceful handling of invalid URLs
- π Detailed Output - Includes URL type and resolution method
π₯ Input
{"channelUrls": www.youtube.com/@rotonmusictv"useApifyProxy": True}
Input Parameters
| Parameter | Type | Required | Default | Description |
|---|---|---|---|---|
channelUrls | String/Array | Yes | - | YouTube channel URLs (one per line) |
useApifyProxy | Boolean | No | false | Enable Apify Proxy |
Supported URL Formats
- Direct Channel ID:
https://www.youtube.com/channel/UC... - Username Handle:
https://www.youtube.com/@username - Custom URL:
https://www.youtube.com/c/channelname - Legacy User:
https://www.youtube.com/user/username
Input Examples
Single Channel:
{"channelUrls": "https://www.youtube.com/@youtube"}
Multiple Channels:
{"channelUrls": ["https://www.youtube.com/@youtube","https://www.youtube.com/channel/UCuAXFkgsw1L7xaCfnd5JJOw","https://www.youtube.com/c/YouTube","https://www.youtube.com/user/YouTube"]}
Text Area Format:
{"channelUrls": "https://www.youtube.com/@youtube\nhttps://www.youtube.com/channel/UCuAXFkgsw1L7xaCfnd5JJOw\nhttps://www.youtube.com/c/YouTube"}
π€ Output
Successful Extraction (Direct)
{"youtubeChannelUrl": "https://www.youtube.com/channel/UCuAXFkgsw1L7xaCfnd5JJOw","channelId": "UCuAXFkgsw1L7xaCfnd5JJOw","urlType": "direct","status": "success"}
Successful Extraction (Resolved)
{"youtubeChannelUrl": "https://www.youtube.com/@youtube","channelId": "UCuAXFkgsw1L7xaCfnd5JJOw","urlType": "username","identifier": "youtube","status": "success"}
Failed Extraction
{"youtubeChannelUrl": "https://www.youtube.com/@invalidchannel","channelId": "Not Found","urlType": "username","identifier": "invalidchannel","error": "Failed to resolve channel ID","status": "failed"}
Summary Record
{"_summary": {"extractedAt": "2026-01-18T12:00:00.000Z","totalChannels": 3,"successCount": 2,"failedCount": 1,"channels": [...]}}
π Usage
On Apify Platform
- Navigate to Actor page
- Click "Try for free" or "Start"
- Paste YouTube channel URLs (one per line)
- Click "Start"
- View results in Dataset
π οΈ How It Works
- URL Parsing - Extracts identifier from URL using regex
- Direct Channel IDs - Returns immediately if URL contains channel ID
- Username Resolution - Uses yt-dlp to resolve @username to channel ID
- Custom URL Resolution - Resolves custom URLs via yt-dlp
- Error Handling - Reports failures with detailed error messages
- Batch Processing - Processes all URLs sequentially
- Summary Generation - Creates summary record with statistics
Invalid YouTube URL
- Ensure URL contains
youtube.comoryoutu.be - Check URL is properly formatted
- Example:
https://www.youtube.com/@usernameβ
Channel ID Not Found
- Channel might be deleted or private
- @username might be incorrect
- Some channels may not have public IDs
- Try using direct channel/ID URL format
Resolution Timeout
- Enable
useApifyProxyif getting blocked - Some channels may take longer to resolve
- Verify channel exists and is public
π Output Data Fields
| Field | Type | Description |
|---|---|---|
youtubeChannelUrl | String | Original input URL |
channelId | String | Extracted YouTube channel ID |
urlType | String | URL format type (direct/username/custom/user) |
identifier | String | Extracted identifier (for non-direct URLs) |
status | String | "success" or "failed" |
error | String | Error message (only if failed) |
π‘ Tips for Best Results
- URL Format: Use complete URLs with https://
- Batch Size: Process 10-20 channels at a time
- Error Checking: Always check
statusfield - Direct URLs: Use channel/ID format when possible (fastest)
- Validation: Verify URLs are YouTube channel links
π Comparison with Original Script
| Feature | Original Script | Apify Actor |
|---|---|---|
| Input | Terminal prompt | Web form / API |
| Output | Local JSON file | Apify Dataset |
| Multiple URLs | Manual loop | Batch processing β |
| VS Code Integration | Auto-open | N/A (cloud-based) |
| Error Handling | Basic | Comprehensive β |
| Proxy Support | No | Yes β |
| Cloud Storage | No | Yes β |
| API Access | No | Yes β |
π― URL Format Examples
β Supported:https://www.youtube.com/channel/UCuAXFkgsw1L7xaCfnd5JJOwhttps://www.youtube.com/@youtubehttps://www.youtube.com/c/YouTubehttps://www.youtube.com/user/YouTubeβ Not Supported:https://www.youtube.com/watch?v=... (video URLs)https://www.youtube.com/playlist?list=... (playlist URLs)