Template:YouTube/doc

This template is used to create an external link to YouTube in the ==External links== section. It may also be used for other YouTube links such as those in External media.

This is not a citation template. Use cite AV media to provide bibliographic citations in footnotes. Alternatively, use cite news if the video is a newscast, or cite episode if the video is in an episodic format.

Video
Usage (one parameter):

Usage (two parameters):

Parameter descriptions:
 * id (or unnamed parameter 1) is the "YouTube video id" which appears as:
 * https://www.youtube.com/watch?v=
 * title (or unnamed parameter 2) gives an optional description that may replace the default title (Video)

Examples (1 parameter):
 * https://www.youtube.com/watch?v=



Examples (2 parameters):

With timestamp
Usage:

Parameter descriptions:
 * time or t is the timestamp within the video for the link target.

Examples:

With channel ID
Usage (one parameter):

Usage (two parameters):

Parameter descriptions:
 * c or channel is the "YouTube channel id" which appears as:
 * https://www.youtube.com/channel/
 * title gives an optional description that may replace the default title (PAGENAME)

Examples (1 parameter):
 * https://www.youtube.com/channel/



Example (2 parameters):

With handle
Usage (one parameter):

Usage (two parameters):

Parameter descriptions:
 * h or handle is the "YouTube channel handle" which appears as:
 * https://www.youtube.com/@
 * title gives an optional description that may replace the default title (PAGENAME)
 * suffix replaces the default " 's " after the channel name. It is only to be used in the rare occasion that the channel name is a compound noun ending in S, and making it possessive does not repeat the S sound. Do not use it for a brand name ending in S, for example Smosh Games, which is a singular entity. See MOS:POSS for more information.

Examples (1 parameter):
 * https://www.youtube.com/@



Example (2 parameters):

Example (3 parameters):
 * https://www.youtube.com/@



With legacy username
Usage (one parameter):

Usage (two parameters):

Parameter descriptions:
 * u or user is the "YouTube channel user's name" which appears as:
 * https://www.youtube.com/user/
 * title gives an optional description that may replace the default title (PAGENAME)
 * suffix replaces the default " 's " after the channel name. It is only to be used in the rare occasion that the channel name is a compound noun ending in S, and making it possessive does not repeat the S sound. Do not use it for a brand name ending in S, for example Smosh Games, which is a singular entity. See MOS:POSS for more information.

Examples (1 parameter):
 * https://www.youtube.com/user/



Example (2 parameters):

Example (3 parameters):
 * https://www.youtube.com/user/



With custom URL
Usage (one parameter):

Usage (two parameters):

Parameter descriptions:
 * custom is the "YouTube channel custom URL" which appears as:
 * https://www.youtube.com/c/
 * title gives an optional description that may replace the default title (PAGENAME)

Example (1 parameter):
 * https://www.youtube.com/c/



Example (2 parameters):

Show
Usage (one parameter):

Usage (two parameters):

Parameter descriptions:
 * s or show is the "YouTube show name" which appears as:
 * https://www.youtube.com/show/
 * title gives an optional description that may replace the default title (PAGENAME)

Examples (1 parameter):
 * https://www.youtube.com/show/



Example (2 parameters):

Playlist
Usage (one parameter):

Usage (two parameters):

Parameter descriptions:
 * p or playlist is the "YouTube playlist id" which appears as:
 * https://www.youtube.com/playlist?list=
 * title gives an optional description that may replace the default title (PAGENAME)

Examples (1 parameter):
 * https://www.youtube.com/playlist?list=



Example (2 parameters):

Suppress wikilink
The link to YouTube can be suppressed with the parameter no. Example:

No ID in template
The template will display an error message if no parameters are provided.

It will display an error message if the parameter provided is not known.

TemplateData
{	"description": "Use this to create an external link to YouTube in the External links section. This is not a citation template.", "params": { "id": { "label": "YouTube video id", "description": "The video id which appears after https://www.youtube.com/watch?v= in the URL", "aliases": [ "1"			],			"example": "9bZkp7q19f0", "type": "string", "suggested": true },		"channel": { "label": "YouTube channel id", "description": "The channel id which appears after https://www.youtube.com/channel/ in the URL", "aliases": [ "c" ],			"example": "UC-9-kyTW8ZkZNDHQJ6FgpwQ", "type": "string", "suggested": true },		"handle": { "label": "YouTube channel handle", "description": "The user name which appears after https://www.youtube.com/@ in the URL", "aliases": [ "h" ],			"example": "PewDiePie", "type": "string" },		"user": { "label": "YouTube legacy username", "description": "The user name which appears after https://www.youtube.com/user/ in the URL", "aliases": [ "u" ],			"example": "pewdiepie", "type": "string" },		"custom": { "label": "YouTube channel custom URL fragment slug", "description": "The channel custom URL slug which appears after https://www.youtube.com/c/ in the URL", "example": "youtube", "type": "string" },		"show": { "label": "YouTube show id", "description": "The show id which appears after https://www.youtube.com/show/ in the URL", "aliases": [ "s" ],			"example": "SCWdVLvom3QaFGxEKNASntaA", "type": "string", "suggested": true },		"playlist": { "label": "YouTube playlist id", "description": "The playlist id which appears after https://www.youtube.com/playlist?list= in the URL", "aliases": [ "p" ],			"example": "PLrEnWoR732-DZV1Jc8bUpVTF_HTPbywpE", "type": "string", "suggested": true },		"title": { "label": "Title", "description": "The name of the page being linked to", "suggested": true, "aliases": [ "2"			],			"example": "Gangnam Style", "default": "If it is a video, Video, if it is a show, the article's page name in italics, otherwise, the article's page name unformatted", "type": "string" },		"suffix": { "label": "Channel title suffix", "description": "Text immediately after the channel title. It is only to be used in the rare occasion that the channel title is a compound noun ending in S, and making it possessive does not repeat the S sound.", "example": "'", "default": "'s", "type": "string" },		"link": { "label": "Link on", "description": "Set this parameter to no to suppress the link to the YouTube article", "example": "no", "type": "string" },		"time": { "aliases": [ "t" ],			"label": "Timestamp", "description": "The timestamp within the video for the link target; usually appears after &t= in the full URL or ?t= in a shortened URL", "example": "3m2s", "type": "string" }	},	"paramOrder": [ "id", "time", "channel", "handle", "user", "custom", "show", "playlist", "title", "suffix", "link" ],	"format": "inline" }

Tracking categories

 * – list of pages using this template with too many parameters, or with invalid text in the title parameter.
 * – list of pages using this template with unsupported parameters.