How to Download 720p High Definition YouTube Videos

This tip was too good not to pass along: a way to download high quality videos from YouTube for free (the high definition ones that have been uploaded in 720p).

You’ve likely already noticed that YouTube has enabled high quality viewing for all users — and if your system’s fast enough, and you have a broadband connection, the first thing you should do is visit your Video Playback Quality page and enable the “I have a fast connection. Always play higher-quality video when it’s available” option. This is apparently a cookie-based setting, which is a bit disappointing (because you have to re-enable it on every computer rather than having it set as a static preference in your YouTube account). Do this, and you’ll always see the best version of a video available.

Now what if you want to save that high quality YouTube video to your computer?

Forget about using a third-party Web site or software to download 720p video from YouTube; there’s nothing for you to install other than this bookmarklet:

Go ahead and create that link into your browser’s Bookmarks (or Favorites) bar. If you’re not familiar with the concept of bookmarklets, they’ve been around forever.

Once this is in your browser’s bookmarks bar, you simply click it when you’re on a YouTube video page that has a 720p (high quality video) that you want to download. You only need click this bookmarklet once. The download doesn’t start – but after clicking this bookmarklet, you should see a new “Download as 720p HD MP4” link in the video information box in the right sidebar of the YouTube page. It’ll be automatically inserted directly beneath the Embed code for that particular video. NOTE: this bookmarklet only works for the 720p videos.

If you want to download any other YouTube video as an MP4, you’ll want to use this bookmarklet: Download YouTube MP4. It works similarly to the HD version of the bookmarklet, only it should work with any YouTube video — and starts downloading the page’s video as an MP4 file without further intervention.

I’m not here to support either bookmarklet, nor to help you figure out how to use either one (beyond the instructions I’ve provided above). If you want to thank anybody, thank Google Operating System and Mac OS X Hints for surfacing the bookmarklets. I’ve tested them on the latest nightly build of WebKit (as of today) and they both work extremely well. Don’t ask me how to get them to work in anything else. 😉

If you want to test it on a video, might I recommend trying it on either my computer giveaway video or the GoToMeeting demonstration?

Hope this helps you download these videos to your computer!

46 thoughts on “How to Download 720p High Definition YouTube Videos”

  1. Thanks you Chris for this good blog post but I couldn’t get it to work on my computer. I am using firefox 3.0.4 and it wouldn’t let me bookmark the javascript code. It is 12/4/08 just so you know because youtube did a redesign of their navigation page.

  2. mitcsoki:
    Internet Explorer does not accept BookMarkerLets, FireFox does.

    Pamela:

    Startube.mobi was not accessable when I tried it.

    Chris:
    All that your bookmarketlet does for me on Mozilla 5.0 is send me back to my home page.

  3. I’m running Firefox 3.0.4. I followed the instructions, clicked the bookmarklet, and nothing happened.

    Here’s something that worked for me however:

    http://www.megaleecher.net/Downloading_Youtuube_Videos_In_Mp4_And_HD_Quality

    This site lets you download an extension that automatically puts those download links in the YouTube sidebar.

    (Once you download the .xpi file, make sure you drag and drop it into an open Firefox window to get the extension install prompt.)

  4. It did not work for me either. Maybe this is because YouTube automatically redirects any YouTube URL to the French version (I live in France). I can watch the videos, but the bookmarklet basically does nothing (on Safari 4.0 build 5528.1).

  5. It doesn’t work for me (i’m too lazy to check why) but you can take the other javascript link (the link on “Download YouTube MP4”) and just change ?fmt=18 to ?fmt=22 . It will start the download of the MP4 hidef video

    You should have this link :
    javascript:if(document.location.href.match(/http://[a-zA-Z.]*youtube.com/watch/)){document.location.href=’http://www.youtube.com/get_video?fmt=22&video_id=’+swfArgs[‘video_id’]+’&t=’+swfArgs[‘t’]}

  6. I got the thing to work, but when I download it It’s NOT the 720p veresion, just the regular ‘watch in higher quality’ version.

    And yes, im using the correct extenstion, and yes, the video im watching is in 720p. help?

  7. Thanks for the insights; I have found that simply pasting the format code designator at the end of the URL for a stadard video does the trick. you add ‘ &fmt=18 ‘ for standard MP4 and ‘ &fmt=22 ‘ for HD 720p (if available) to the standard URL for a youtube video. If you go into your IE explorer browser cache (even up to IE 7) the file is there (I go to the cache and sort the files largest to smallest).

    With this method there is no need to use script plugins OR external sites. You just set up a shortcut to your browser cache ‘Temporary Internet Files’ folder in windows.

  8. i use this from the official google blog
    javascript:if(document.location.href.match(/http://[a-zA-Z.]*youtube.com/watch/)){document.location.href=’http://www.youtube.com/get_video?fmt=’+(isHDAvailable?’22’:’18’)+’&video_id=’+swfArgs[‘video_id’]+’&t=’+swfArgs[‘t’]}

    @Jacob
    NO IT IS NOT ILLEGAL (but against the TOS) SINCE YOU HAVE ALREADY DOWNLOADED IT BY WATCHING IT!

  9. Yeah, none of the things on this page worked at all for me. Also, even given a few arguments, /get_video is a blank page.

  10. Chris, the characters in your URL are escaped. That makes it not work for me and I’m too lazy to manually unescape it.

    mark on Feb 27th has a working link. All single-quotes were replaced by different characters, probably when posting here, and you need to paste in Notepad and manually change them back before use.

  11. I made it clearer for all three video format offered by youtube, FLV, MP4 and HD.

    Here:

    FLV

    javascript:if(document.location.href.match(/http://[a-zA-Z.]*youtube.com/watch/)){document.location.href=’http://www.youtube.com/get_video?video_id=’+swfArgs[‘video_id’]+’&t=’+swfArgs[‘t’]}

    MP4

    javascript:if(document.location.href.match(/http://[a-zA-Z.]*youtube.com/watch/)){document.location.href=’http://www.youtube.com/get_video?fmt=18&video_id=’+swfArgs[‘video_id’]+’&t=’+swfArgs[‘t’]}

    HD

    javascript:if(document.location.href.match(/http://[a-zA-Z.]*youtube.com/watch/)){document.location.href=’http://www.youtube.com/get_video?fmt=22&video_id=’+swfArgs[‘video_id’]+’&t=’+swfArgs[‘t’]}


    Notice the only difference is after the get_video?, either fmt=22& or fmt=18& for HD and MP4 respectively are added. Simply remove to get the old FLV file. I prefer to have more control over which format I want, so I made these three bookmarklets name YT: FLV, YT: MP4 and YT: HD.

    NOTE!
    If using the first bookmarklet posted on this site won’t work, most likely the video is not available in HD. Use MP4 instead, or even if still not working, FLV.

  12. I’m screaming and pulling my hair, cursing and screaming again. I turned on links in the menu thingy at the top of vista machiney. So for me to download a 720p video from youtube, in plain english, all I have to do is put the

    javascript:if(document.location.href.match(/http://[a-zA-Z.]*youtube.com/watch/)){document.location.href=’http://www.youtube.com/get_video?fmt=22&video_id=’+swfArgs[‘video_id’]+’&t=’+swfArgs[‘t’]}

    IN WHEREEEEEE!!!!!!!!!!!!!!!!!!
    After I highlight it what do I do click by click?

  13. What an absolute and utter waste of time. Learn how to do something properly before posting crappy scripts on the net.

  14. I’m trying to use it with Google Chrome, and its not working.
    Is it that chrome doesn’t support it?

  15. Thanks for this. I found Alex’s post to be the best with the 3 different bookmarklets.

    Someone asked about how to just get “HQ” (it’s just MP4):
    FLV = low quality (.flv file)
    MP4 = HQ (med) quality (.mp4 file)
    HD = HD (high) quality (still .mp4 file)

    The problems most people are seeing here are probably typos that must be fixed (you can’t just cut and paste). In Alex’s post, you have to copy the code to a text editor and replace the apostrophes (4 in each) with single quotes – look carefully since they almost look exactly the same.

    To create a bookmarklet, just find out how to create a plain new bookmark in your browser. You can name it whatever you want, then use the posted code above, starting with “javascript…” (with typos corrected), for the address (url). Try the new bookmarklet in the window with the video. If you are getting errors in your javascript console window, then you still have typos to fix. Otherwise the file should auto-download.

    Hope that helps.

  16. Nothing worked for me, but.. guess what: just copy the URL in jdownloader and it will download the HQ-temp file, convert it to mp4 and you have the best available quality. simple.

  17. This sucks. How do you take the code and make it into a bookmarklet? How could he leave that out??

  18. ok I figured out the coding thanks to Rick/Alex but in the end it doesn’t work anyway. Nice way to waste an hour…

  19. I used to download videos this way but for some reason the download button doesn’t work anymore.

    Any ideas?

    P.S. Sorry for ani mistake, english is not my language :p

  20. yea. same here. i used this alot. im not sure if youtube just updated there site. the link for the mp4 download no longer works

  21. someone,could you help me? i have a very-dumb question.
    here, i don’t know about this tutorial at all it’s too complicated (because the language).
    if i want to make some gif, what the very first thing i need? and how could i get that?
    and what’s next step after that?
    please explain to me from the first until the last with very based language,my english is not good at all.

    thanks 🙂

  22. Better yet, download firefox, then download this add-on called Download Helper from here: https://addons.mozilla.org/firefox/3006/

    1. After you have it installed, go to the youtube video you want to download.

    2. Click on the little arrow to the left of the address bar near the red, yellow, and blue balloons… and you’ll get the option to download that video in all the resolutions possible.

    3. Click on the 720p option (or whichever you want).

    4. Save it to whatever folder you wish.

    5. Now you have to leave that Youtube web page or close it down, because then you’ll technically be downloading the video to your computer and streaming the video at the same time. This will free up bandwidth for the video to download faster.

  23. javascript:var getQualityLink=function() { var oEndLnk = ‘&title=’ + escape(document.getElementById(‘eow-title’).getAttribute(‘title’)); for(i=0;i<yt.getConfig('PLAYER_CONFIG').args.fmt_url_map.split(',').length;i++) { var ytPlayerConf = yt.getConfig('PLAYER_CONFIG').args.fmt_url_map.split(',')[i].split('|')[0]; if(ytPlayerConf == 37 || ytPlayerConf == 22 || ytPlayerConf == 18) { return yt.getConfig('PLAYER_CONFIG').args.fmt_url_map.split(',')[i].split('|')[1] + oEndLnk; }; }; return yt.getConfig('PLAYER_CONFIG').args.fmt_url_map.split(',')[0].split('|')[1] + oEndLnk; }; var createLink=function( l,t) { var oLnk=document.createElement( 'a') ;oLnk.setAttribute( 'href',l) ;oLnk.appendChild(document.createElement('br'));var oImg=document.createElement('img'); oImg.src='http://www.orbitdownloader.com/img2/download-botton.gif&#039;; oLnk.appendChild( oImg );oLnk.setAttribute( 'style','display:inline;font:14px Times New Roman;text-decoration:underline;text-transform:none;') ;return oLnk} ; function enableDownload() { document.getElementById('watch-info').appendChild( createLink( getQualityLink(), 'Download') ); }; enableDownload();

  24. Updated Bookmarklet that Creates Download Button on the Page (credits go to me 😛 (if it doesn’t work by copying and pasting this code try http://anonymouslyacquired.info/ytdownload.js )):

    javascript:var getQualityLink=function() { var oEndLnk = ‘&title=’ + escape(document.getElementById(‘eow-title’).getAttribute(‘title’)); for(i=0;i<yt.getConfig('PLAYER_CONFIG').args.fmt_url_map.split(',').length;i++) { var ytPlayerConf = yt.getConfig('PLAYER_CONFIG').args.fmt_url_map.split(',')[i].split('|')[0]; if(ytPlayerConf == 37 || ytPlayerConf == 22 || ytPlayerConf == 18) { return yt.getConfig('PLAYER_CONFIG').args.fmt_url_map.split(',')[i].split('|')[1] + oEndLnk; }; }; return yt.getConfig('PLAYER_CONFIG').args.fmt_url_map.split(',')[0].split('|')[1] + oEndLnk; }; var createLink=function( l,t) { var oLnk=document.createElement( 'a') ;oLnk.setAttribute( 'href',l) ;oLnk.appendChild(document.createElement('br'));var oImg=document.createElement('img'); oImg.src='http://www.orbitdownloader.com/img2/download-botton.gif&#039;; oLnk.appendChild( oImg );oLnk.setAttribute( 'style','display:inline;font:14px Times New Roman;text-decoration:underline;text-transform:none;') ;return oLnk} ; function enableDownload() { document.getElementById('watch-info').appendChild( createLink( getQualityLink(), 'Download') ); }; enableDownload();

  25. Works great in Chrome on PC.. I had to refresh the page once I clicked the bookmarklet. Great post. THANKS !

Comments are closed.