Click here to Skip to main content
13,589,782 members
Click here to Skip to main content
Add your own
alternative version


26 bookmarked
Posted 2 Feb 2011
Licenced CPOL

YouTube® playback customization options

, 14 Feb 2015
Rate this:
Please Sign up or sign in to vote.
Customize YouTube® video playback by adding web query parameters

Following examples demonstrate YouTube playback customization technique by adding web query parameters to the video URL (i.e. the links to YouTube video items).

Setting the video playback starting point

Setting the video playback starting point by specifying the offset-time in minutes and seconds from the beginning of video clip (in this example, it is set to 1min:10 sec, which will force the player to start the sample car video at "German Cars" fragment):[^],
where parameter "NGRgHj9hsqw" represents the actual video item ID in YouTube classification system; this is the mandatory part of YouTube URL string. Parameter &t=1m10s specifies the video playback starting point. Alternatively, it could be coded in the following format: #t=1m10s

Shortening video URL

Entire URL with added web query could be shortened by using, for example, service and look like:[^]); all customization options will be preserved in the short URL.

Full Screen Mode

Playback in a Full Screen mode:[^], where NGRgHj9hsqw represents the video id.


Playback Autoplay option in a full-screen mode is set to "OFF" by default. In order to turn it "ON", add the parameter "&autoplay=1" to the end of the URL web query.


Playback Loop (number of video re-plays) could be specified by adding the following parameter: “&loop=2” to the end of the query to play the video twice or “&loop=3” to replay it three times and so on.

Related Videos option On/Off

Turn “OFF” the "Related Video" option to filter-off "extras" from the video port by adding “&rel=0” to the end of the web query.


Embedded YouTube Player (click on image to open DEMO)

Sample screen shot of embedded YouTube Player


This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


About the Author

Founder Infosoft International Inc
United States United States
Dr. Alexander Bell is a seasoned full-stack Software Engineer (Win/Web/Mobile). He holds PhD in EE/IT, authored 37 inventions and published 300+ technical articles. Currently focused on Java/Javascript, .NET/C#, Android/Mobile, SQL, 'Big Data', Machine Learning, AI, IoT. Alex participated in App Innovation Contests (AIC 2102/2013) with multiple winning submissions. Portfolio samples:

  1. Real-time NY Bus Tracking Web App (IoT)
  2. Android Fraction Calculator "Fractal MK-12"
  3. Android Prime Factorization Calculator 18-digit)
  4. Semaphon™ semantic phone num-to-text converter
  5. Educational Web Portal
  6. Free Online NY Payroll Tax Calculator
  7. WebTV powered by YouTube Player powered by .NET API (#1 on Google)
  8. Engineering Calculator VOLTA
  9. Big Data: Facebook and YouTube
  10. NY City Trivia Quiz
  11. Publications by A. Bell

You may also be interested in...

Comments and Discussions

GeneralRe: To the member "brutuscat"- 1. I am giving you a second warni... Pin
DrABELL29-Mar-11 8:29
memberDrABELL29-Mar-11 8:29 
GeneralRe: To the member "brutuscat"- 1. You are wrong on your assumpti... Pin
DrABELL29-Mar-11 5:20
memberDrABELL29-Mar-11 5:20 
GeneralRe: The reason and the point are that you are not adding any val... Pin
brutuscat29-Mar-11 3:39
memberbrutuscat29-Mar-11 3:39 
GeneralReason for my Vote of 5 Very good share and nice highlightin... Pin
RaviRanjankr3-Nov-11 22:17
mvpRaviRanjankr3-Nov-11 22:17 
GeneralReason for my vote of 5 This probably exists in some documen... Pin
JH6420-Jun-11 13:40
memberJH6420-Jun-11 13:40 
GeneralRe: Thanks a bunch! Pin
DrABELL20-Jun-11 15:00
memberDrABELL20-Jun-11 15:00 
GeneralReason for my vote of 5 Good tip! Very good share, I never k... Pin
EdMan1965-Jun-11 23:30
memberEdMan1965-Jun-11 23:30 
GeneralRe: Thanks a bunch, Ed! I am totally agree with you. And, btw, a... Pin
DrABELL6-Jun-11 5:23
memberDrABELL6-Jun-11 5:23 
GeneralReason for my vote of 1 There is a thing called Documentatio... Pin
brutuscat28-Mar-11 23:50
memberbrutuscat28-Mar-11 23:50 
GeneralRe: What is the point of your message and the reason for such un... Pin
DrABELL29-Mar-11 3:25
memberDrABELL29-Mar-11 3:25 
Generalnice ,my 5+ Pin
Monjurul Habib5-Mar-11 7:27
memberMonjurul Habib5-Mar-11 7:27 
GeneralRe: Thanks a lot! Pin
DrABELL8-Mar-11 17:18
memberDrABELL8-Mar-11 17:18 
GeneralReason for my vote of 5 nice,my5 Pin
Monjurul Habib5-Mar-11 7:26
memberMonjurul Habib5-Mar-11 7:26 
GeneralReason for my vote of 5 Good one dude Pin
thatraja5-Mar-11 3:01
mvpthatraja5-Mar-11 3:01 
GeneralRe: Many thanks! :) Pin
DrABELL5-Mar-11 4:13
memberDrABELL5-Mar-11 4:13 
GeneralThanks! Pin
DrABELL21-Feb-11 17:01
memberDrABELL21-Feb-11 17:01 
GeneralThis is awesome! Pin
LopeZ10121-Feb-11 11:41
memberLopeZ10121-Feb-11 11:41 
General<i>More on this topic, covering the embedded YouTube player:... Pin
DrABELL3-Feb-11 6:23
memberDrABELL3-Feb-11 6:23 
GeneralReason for my vote of 5 you really hacked it! By the way nic... Pin
GPUToaster2-Feb-11 18:30
memberGPUToaster2-Feb-11 18:30 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.

Permalink | Advertise | Privacy | Cookies | Terms of Use | Mobile
Web02-2016 | 2.8.180618.1 | Last Updated 14 Feb 2015
Article Copyright 2011 by DrABELL
Everything else Copyright © CodeProject, 1999-2018
Layout: fixed | fluid