TranscriptFetch
Back to blog
Guide·Jul 11, 2026·10 min read

What Is URL on YouTube? A Developer Guide to YouTube URL Formats, IDs, and Transcript Retrieval

What is URL on YouTube? Learn every YouTube link format, how to extract video and playlist IDs, and how to fetch transcripts reliably.

Chandler Caseyby Chandler Casey

What is a URL on YouTube?

If you searched what is URL on YouTube, the short answer is simple:

A YouTube URL is the web address that points to a specific YouTube resource, such as a video, Short, playlist, channel, or embed.

For example, https://www.youtube.com/watch?v=dQw4w9WgXcQ is a YouTube URL for a single video. That address contains a video identifier, optional tracking or playback parameters, and enough structure for a browser or API client to know what content to load.

For developers, this matters because users rarely send you a clean, uniform YouTube link format. They paste watch URLs, youtu.be short links, Shorts URLs, playlist links, mobile links, and sometimes malformed fragments copied from chat apps. If your app needs transcripts, metadata, or downstream AI processing, you need to normalize those inputs before calling an API.

This guide explains what a YouTube URL is, how each format works, how to safely extract IDs, and how to send any supported YouTube URL into TranscriptFetch using the YouTube transcript generator, the docs, and the API reference.

Why understanding YouTube URL format matters

A YouTube link is not just a string. It usually carries one or more identifiers:

  • A video ID, often in v= or in the path
  • A playlist ID, often in list=
  • A channel identifier, sometimes in /channel/, /@handle, or /c/
  • Optional playback state, such as start time
  • Optional attribution or share parameters

If you parse the wrong part, you can:

  • request the wrong transcript
  • fail on Shorts or embed URLs
  • lose playlist context
  • treat a channel URL like a video URL
  • accept invalid domains that only look like YouTube

YouTube itself documents platform behavior in its official developer resources at developers.google.com/youtube. General URL structure is also standardized at the web level by RFC 3986.

Anatomy of a YouTube URL

A YouTube URL typically has three parts:

  1. Domain: where the resource lives
  2. Path: what kind of resource it is
  3. Query parameters: extra identifiers or playback instructions

Visual breakdown of a watch URL

text
https://www.youtube.com/watch?v=dQw4w9WgXcQ&t=43s&list=PL1234567890ABCDEF
|------ domain -------| |path| |-------------- query parameters ---------------|

Breakdown:

  • Domain: www.youtube.com
  • Path: /watch
  • Query parameters:
    • v=dQw4w9WgXcQ identifies the video
    • t=43s starts playback at 43 seconds
    • list=PL1234567890ABCDEF indicates playlist context

What parts actually matter for transcript retrieval?

For transcript APIs, the important part is usually the video ID. Playlist and channel IDs matter when you are processing many videos or expanding a collection.

In other words:

  • For a single transcript, extract the video ID
  • For playlist processing, extract the playlist ID
  • For channel ingestion, extract the channel identifier

Common YouTube URL formats

This is the part most developers need as a reference. These are the most common YouTube URL patterns you will see in production.

Supported YouTube URL patterns at a glance

TypePatternExampleMain identifier
Watch videohttps://www.youtube.com/watch?v=VIDEO_IDhttps://www.youtube.com/watch?v=dQw4w9WgXcQVIDEO_ID from v
Short linkhttps://youtu.be/VIDEO_IDhttps://youtu.be/dQw4w9WgXcQVIDEO_ID from path
Shortshttps://www.youtube.com/shorts/VIDEO_IDhttps://www.youtube.com/shorts/dQw4w9WgXcQVIDEO_ID from path
Embedhttps://www.youtube.com/embed/VIDEO_IDhttps://www.youtube.com/embed/dQw4w9WgXcQVIDEO_ID from path
Playlisthttps://www.youtube.com/playlist?list=PLAYLIST_IDhttps://www.youtube.com/playlist?list=PL1234567890ABCDEFPLAYLIST_ID from list
Watch within playlisthttps://www.youtube.com/watch?v=VIDEO_ID&list=PLAYLIST_IDhttps://www.youtube.com/watch?v=dQw4w9WgXcQ&list=PL1234567890ABCDEFVIDEO_ID, PLAYLIST_ID
Channel by IDhttps://www.youtube.com/channel/CHANNEL_IDhttps://www.youtube.com/channel/UC_x5XG1OV2P6uZZ5FSM9TtwCHANNEL_ID from path
Channel handlehttps://www.youtube.com/@handlehttps://www.youtube.com/@YouTubeCreatorshandle from path
Custom channel URLhttps://www.youtube.com/c/Namehttps://www.youtube.com/c/YouTubeCreatorscustom name
User channel URLhttps://www.youtube.com/user/Namehttps://www.youtube.com/user/YouTubeusername
Mobile watchhttps://m.youtube.com/watch?v=VIDEO_IDhttps://m.youtube.com/watch?v=dQw4w9WgXcQVIDEO_ID from v
Music watchhttps://music.youtube.com/watch?v=VIDEO_IDhttps://music.youtube.com/watch?v=dQw4w9WgXcQVIDEO_ID from v

How to find the video ID, playlist ID, and channel identifier

How do I find a YouTube video ID from a URL?

A YouTube video ID is the unique string that identifies one video. In many cases it is 11 characters, for example dQw4w9WgXcQ.

Common places to find it:

  • watch?v=dQw4w9WgXcQ → read v
  • youtu.be/dQw4w9WgXcQ → read the first path segment
  • /shorts/dQw4w9WgXcQ → read the segment after /shorts/
  • /embed/dQw4w9WgXcQ → read the segment after /embed/

How do I find a YouTube playlist ID?

Look for the list query parameter:

text
https://www.youtube.com/playlist?list=PL1234567890ABCDEF

Here, the playlist ID is PL1234567890ABCDEF.

You may also see playlist context attached to a normal watch URL:

text
https://www.youtube.com/watch?v=dQw4w9WgXcQ&list=PL1234567890ABCDEF

That URL contains both a video ID and a playlist ID.

How do I find a YouTube channel identifier?

There are several channel URL formats:

  • /channel/UC... → direct channel ID
  • /@handle → handle
  • /c/name → custom channel path
  • /user/name → legacy username path

If you need stable machine processing, channel IDs are best. Handles are also useful, but custom and legacy paths may require resolution through API or scraping workflows.

YouTube URL examples: watch, youtu.be, Shorts, embed, playlist, channel, handle

Below are the formats people paste most often into apps.

Watch URL

text
https://www.youtube.com/watch?v=dQw4w9WgXcQ
  • Resource type: video
  • Key identifier: v=dQw4w9WgXcQ

Shortened youtu.be URL

text
https://youtu.be/dQw4w9WgXcQ
  • Resource type: video
  • Key identifier: path segment dQw4w9WgXcQ

YouTube Shorts URL format

text
https://www.youtube.com/shorts/dQw4w9WgXcQ
  • Resource type: Short video
  • Key identifier: path segment after /shorts/

Embed URL

text
https://www.youtube.com/embed/dQw4w9WgXcQ
  • Resource type: embeddable video
  • Key identifier: path segment after /embed/

Playlist URL format

text
https://www.youtube.com/playlist?list=PL1234567890ABCDEF
  • Resource type: playlist
  • Key identifier: list

Channel URL format

text
https://www.youtube.com/channel/UC_x5XG1OV2P6uZZ5FSM9Ttw
  • Resource type: channel
  • Key identifier: channel path segment

Handle URL format

text
https://www.youtube.com/@YouTubeCreators
  • Resource type: channel handle
  • Key identifier: handle in path

Query parameters explained: v, list, t, start, si, feature

These are the parameters developers should recognize immediately.

v

The primary video identifier on watch URLs.

Example:

text
/watch?v=dQw4w9WgXcQ

list

The playlist identifier.

Example:

text
/watch?v=dQw4w9WgXcQ&list=PL1234567890ABCDEF

t

Playback start time, often from shared links.

Examples:

  • t=43s
  • t=90

This usually does not change the transcript resource. It only affects playback position.

start

Another start-time parameter, common in embeds.

Example:

text
/embed/dQw4w9WgXcQ?start=60

si

A newer share-related parameter commonly appended by YouTube.

Example:

text
https://youtu.be/dQw4w9WgXcQ?si=abcd1234

In most transcript workflows, si can be ignored.

feature

A context or source indicator, such as share source or app surface.

Example:

text
/watch?v=dQw4w9WgXcQ&feature=youtu.be

This is usually non-essential for content retrieval.

Valid and invalid YouTube URLs

Valid YouTube URLs

These are generally safe to accept after normalization:

  • https://www.youtube.com/watch?v=dQw4w9WgXcQ
  • https://youtu.be/dQw4w9WgXcQ
  • https://m.youtube.com/watch?v=dQw4w9WgXcQ
  • https://music.youtube.com/watch?v=dQw4w9WgXcQ
  • https://www.youtube.com/shorts/dQw4w9WgXcQ
  • https://www.youtube.com/embed/dQw4w9WgXcQ
  • https://www.youtube.com/playlist?list=PL1234567890ABCDEF

Invalid or unsafe inputs

Reject or flag these:

  • non-YouTube domains pretending to be YouTube
  • youtube.com/watch with no v
  • youtu.be/ with no path ID
  • random text pasted instead of a URL
  • URLs with broken encoding or truncated query strings
  • copied links where the ID includes trailing punctuation, such as ) or .

Support and non-support checklist

CaseUsually processable?Notes
Public videoYesBest case for transcript retrieval
Public ShortYesNormalize to the underlying video ID
Public playlistYesExtract list, then iterate videos
Public channel URLYesChannel resolution may be needed
Live streamSometimesActive live streams may not have transcript availability yet
Private videoNoAccess restricted
Deleted videoNoResource unavailable
Region-blocked videoSometimesDepends on retrieval path and availability
Malformed URLNoNormalize or reject before API call

How developers should normalize YouTube URLs before processing

A good normalizer does four things:

  1. validates the hostname
  2. identifies the resource type from path and query
  3. extracts the correct identifier
  4. strips irrelevant parameters

JavaScript function to normalize YouTube URLs and extract IDs

js
function normalizeYouTubeUrl(input) {
  let url;
  try {
    url = new URL(input);
  } catch {
    return { valid: false, error: 'Invalid URL' };
  }

  const host = url.hostname.replace(/^www\./, '').toLowerCase();
  const allowedHosts = new Set([
    'youtube.com',
    'm.youtube.com',
    'music.youtube.com',
    'youtu.be'
  ]);

  if (!allowedHosts.has(host)) {
    return { valid: false, error: 'Unsupported hostname' };
  }

  const path = url.pathname;
  const params = url.searchParams;

  let type = null;
  let videoId = null;
  let playlistId = null;
  let channelId = null;
  let handle = null;

  if (host === 'youtu.be') {
    type = 'video';
    videoId = path.split('/').filter(Boolean)[0] || null;
  } else if (path === '/watch') {
    videoId = params.get('v');
    playlistId = params.get('list');
    type = videoId ? 'video' : playlistId ? 'playlist' : null;
  } else if (path.startsWith('/shorts/')) {
    type = 'video';
    videoId = path.split('/')[2] || null;
  } else if (path.startsWith('/embed/')) {
    type = 'video';
    videoId = path.split('/')[2] || null;
  } else if (path === '/playlist') {
    type = 'playlist';
    playlistId = params.get('list');
  } else if (path.startsWith('/channel/')) {
    type = 'channel';
    channelId = path.split('/')[2] || null;
  } else if (path.startsWith('/@')) {
    type = 'channel';
    handle = path.slice(2);
  } else if (path.startsWith('/c/') || path.startsWith('/user/')) {
    type = 'channel';
  }

  if (!type) {
    return { valid: false, error: 'Unsupported YouTube URL format' };
  }

  const normalized = new URL('https://www.youtube.com/');

  if (type === 'video' && videoId) {
    normalized.pathname = '/watch';
    normalized.searchParams.set('v', videoId);
  }

  if (type === 'playlist' && playlistId) {
    normalized.pathname = '/playlist';
    normalized.searchParams.set('list', playlistId);
  }

  if (type === 'channel' && channelId) {
    normalized.pathname = `/channel/${channelId}`;
  }

  if (type === 'channel' && handle) {
    normalized.pathname = `/@${handle}`;
  }

  return {
    valid: true,
    type,
    videoId,
    playlistId,
    channelId,
    handle,
    normalizedUrl: normalized.toString()
  };
}

Python example for parsing YouTube URLs safely

This version uses the standard library only.

python
from urllib.parse import urlparse, parse_qs

ALLOWED_HOSTS = {
    "youtube.com",
    "www.youtube.com",
    "m.youtube.com",
    "music.youtube.com",
    "youtu.be",
    "www.youtu.be",
}


def parse_youtube_url(raw_url: str) -> dict:
    parsed = urlparse(raw_url)

    if not parsed.scheme or not parsed.netloc:
        return {"valid": False, "error": "Invalid URL"}

    host = parsed.netloc.lower()
    if host not in ALLOWED_HOSTS:
        return {"valid": False, "error": "Unsupported hostname"}

    path_parts = [p for p in parsed.path.split("/") if p]
    query = parse_qs(parsed.query)

    result = {
        "valid": True,
        "type": None,
        "video_id": None,
        "playlist_id": None,
        "channel_id": None,
        "handle": None,
    }

    if host.endswith("youtu.be"):
        result["type"] = "video"
        result["video_id"] = path_parts[0] if path_parts else None
        return result

    if parsed.path == "/watch":
        result["video_id"] = query.get("v", [None])[0]
        result["playlist_id"] = query.get("list", [None])[0]
        result["type"] = "video" if result["video_id"] else "playlist" if result["playlist_id"] else None
        return result

    if len(path_parts) >= 2 and path_parts[0] in {"shorts", "embed", "live"}:
        result["type"] = "video"
        result["video_id"] = path_parts[1]
        return result

    if parsed.path == "/playlist":
        result["type"] = "playlist"
        result["playlist_id"] = query.get("list", [None])[0]
        return result

    if len(path_parts) >= 2 and path_parts[0] == "channel":
        result["type"] = "channel"
        result["channel_id"] = path_parts[1]
        return result

    if path_parts and path_parts[0].startswith("@"):
        result["type"] = "channel"
        result["handle"] = path_parts[0][1:]
        return result

    return {"valid": False, "error": "Unsupported YouTube URL format"}

Fetch a transcript from any supported YouTube URL with TranscriptFetch

Once the URL is normalized, you can pass the full YouTube URL into TranscriptFetch and let the API retrieve the transcript-ready resource.

If you want to test manually, start with the YouTube transcript generator. For implementation details, use the docs and API reference. If you plan to process lots of videos, check pricing.

curl example

bash
curl -X POST "https://api.transcriptfetch.com/v1/transcripts" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "url": "https://youtu.be/dQw4w9WgXcQ?si=abcd1234&t=43s"
  }'

Example response shape:

json
{
  "source": "youtube",
  "videoId": "dQw4w9WgXcQ",
  "language": "en",
  "transcript": [
    {"start": 0.0, "duration": 2.1, "text": "Hello and welcome"},
    {"start": 2.1, "duration": 3.4, "text": "Today we are covering..."}
  ]
}

JavaScript example

js
const response = await fetch('https://api.transcriptfetch.com/v1/transcripts', {
  method: 'POST',
  headers: {
    'Authorization': `Bearer ${process.env.TRANSCRIPTFETCH_API_KEY}`,
    'Content-Type': 'application/json'
  },
  body: JSON.stringify({
    url: 'https://www.youtube.com/shorts/dQw4w9WgXcQ'
  })
});

if (!response.ok) {
  const error = await response.json();
  throw new Error(`${error.error.code}: ${error.error.message}`);
}

const data = await response.json();
console.log(data.videoId, data.transcript.length);

Python example

python
import os
import requests

resp = requests.post(
    "https://api.transcriptfetch.com/v1/transcripts",
    headers={
        "Authorization": f"Bearer {os.environ['TRANSCRIPTFETCH_API_KEY']}",
        "Content-Type": "application/json",
    },
    json={
        "url": "https://www.youtube.com/watch?v=dQw4w9WgXcQ&feature=youtu.be"
    },
    timeout=30,
)

resp.raise_for_status()
data = resp.json()
print(data["videoId"])
print(data["transcript"][:2])

Processing playlists and channels

For larger ingestion workflows, developers typically:

  • submit a playlist URL, extract video URLs, then fetch transcripts in batch
  • submit a channel URL, enumerate recent videos, then fetch transcripts per video

Use the TranscriptFetch documentation for transcript retrieval, channel transcripts, playlist processing, and error codes via the docs and API reference. The blog also has workflow ideas for AI and search pipelines.

Common errors and edge cases

This is where production systems usually break.

Malformed shared URLs

Example:

text
https://www.youtube.com/watch?v=dQw4w9WgXcQ).

Problem: trailing punctuation copied from email or docs.

Fix: trim surrounding punctuation before parsing.

Mobile and music subdomains

Examples:

  • https://m.youtube.com/watch?v=...
  • https://music.youtube.com/watch?v=...

Problem: some parsers only allow www.youtube.com.

Fix: allow known YouTube host variants and normalize back to canonical form.

Shorts input treated as unsupported

Problem: older parsers only support /watch?v=.

Fix: explicitly handle /shorts/{id} and map it to the video resource.

Playlist-only links sent to video-only pipelines

Example:

text
https://www.youtube.com/playlist?list=PL1234567890ABCDEF

Problem: there is no v parameter.

Fix: detect playlist type first, then route to playlist processing logic.

Private, deleted, or unavailable videos

Even a perfectly valid YouTube URL can fail if the resource is not accessible.

Realistic API error shapes you may see:

json
{
  "error": {
    "code": "resource_unavailable",
    "message": "The YouTube video is private, deleted, or otherwise unavailable."
  }
}
json
{
  "error": {
    "code": "transcript_not_found",
    "message": "No transcript was available for the requested video."
  }
}
json
{
  "error": {
    "code": "invalid_source_url",
    "message": "The provided URL is not a supported YouTube resource."
  }
}

For implementation guidance, keep the API reference handy and map known error codes in your client.

FAQ

What is a YouTube URL?

A YouTube URL is the web address for a YouTube resource, such as a video, playlist, channel, Short, or embed.

What is the standard YouTube link format for videos?

The most common format is:

text
https://www.youtube.com/watch?v=VIDEO_ID

A shortened format is:

text
https://youtu.be/VIDEO_ID

How do I find my YouTube video URL?

Open the video in YouTube, then copy the address from the browser bar or use YouTube's Share button.

How do I get the YouTube video ID from a URL?

Check the v parameter on watch URLs, or read the path segment on youtu.be, /shorts/, and /embed/ links.

What is the YouTube Shorts URL format?

A YouTube Shorts URL usually looks like this:

text
https://www.youtube.com/shorts/VIDEO_ID

What is the YouTube playlist URL format?

A playlist URL usually looks like this:

text
https://www.youtube.com/playlist?list=PLAYLIST_ID

What is the YouTube channel URL format?

Common channel URL formats include:

  • https://www.youtube.com/channel/CHANNEL_ID
  • https://www.youtube.com/@handle
  • https://www.youtube.com/c/customname

Can I send a full YouTube URL directly to TranscriptFetch?

Yes, that is the practical workflow. Send the full supported YouTube URL, let your app normalize it, and then retrieve the transcript through TranscriptFetch.

Do query parameters like t, si, or feature change the transcript?

Usually no. They affect playback or sharing context, not the underlying video identity.

Are private or deleted YouTube videos supported?

No. A URL can be structurally valid but still point to content that is inaccessible or removed.

Final takeaways for developers

If your goal is to answer what is url on YouTube for both beginners and builders, the key point is this: a YouTube URL is the address for a YouTube resource, but different URL formats expose different identifiers in different places.

The practical workflow is straightforward:

  1. accept the full input URL
  2. validate the hostname
  3. detect the resource type
  4. extract v, list, channel ID, or handle
  5. normalize away unnecessary parameters
  6. send the cleaned URL to TranscriptFetch

That approach handles common watch links, youtu.be shares, Shorts, embeds, playlists, and channel URLs far more reliably than a one-pattern parser.

If you want to put this into production, start with the YouTube transcript generator, then implement against the docs and API reference. For AI workflows that summarize, classify, or search across transcripts, the OpenAI platform docs are a useful companion reference.

Article schema

html
<script type="application/ld+json">
{
  "@context": "https://schema.org",
  "@type": "Article",
  "headline": "What Is URL on YouTube? A Developer Guide to YouTube URL Formats, IDs, and Transcript Retrieval",
  "description": "What is URL on YouTube? Learn every YouTube link format, how to extract video and playlist IDs, and how to fetch transcripts reliably.",
  "author": {
    "@type": "Organization",
    "name": "TranscriptFetch"
  },
  "publisher": {
    "@type": "Organization",
    "name": "TranscriptFetch"
  },
  "mainEntityOfPage": "https://transcriptfetch.com/blog/what-is-url-on-youtube"
}
</script>

FAQ schema

html
<script type="application/ld+json">
{
  "@context": "https://schema.org",
  "@type": "FAQPage",
  "mainEntity": [
    {
      "@type": "Question",
      "name": "What is a YouTube URL?",
      "acceptedAnswer": {
        "@type": "Answer",
        "text": "A YouTube URL is the web address for a YouTube resource, such as a video, playlist, channel, Short, or embed."
      }
    },
    {
      "@type": "Question",
      "name": "How do I get the YouTube video ID from a URL?",
      "acceptedAnswer": {
        "@type": "Answer",
        "text": "Check the v parameter on watch URLs, or read the path segment on youtu.be, /shorts/, and /embed/ links."
      }
    },
    {
      "@type": "Question",
      "name": "What is the YouTube Shorts URL format?",
      "acceptedAnswer": {
        "@type": "Answer",
        "text": "A YouTube Shorts URL usually looks like https://www.youtube.com/shorts/VIDEO_ID."
      }
    },
    {
      "@type": "Question",
      "name": "Can I send a full YouTube URL directly to TranscriptFetch?",
      "acceptedAnswer": {
        "@type": "Answer",
        "text": "Yes. Send the full supported YouTube URL, normalize it in your application if needed, and retrieve the transcript through TranscriptFetch."
      }
    }
  ]
}
</script>