Download YouTube Videos as MP4 Files

An interesting side-effect of YouTube’s recent push for higher quality videos is that most videos can be downloaded as MP4 files directly from YouTube. Until now, you could only get FLV files from your browser’s cache or using one of the many websites that let you download YouTube videos. In fact, to download the MP4 files, you need to use the same URL like for FLV files and append “&fmt=18“:

http://www.youtube.com/get_video?video_id=ID&t=SIGNATURE&fmt=18

ID is the video’s identification value, SIGNATURE is a value that prevents you from downloading the file just by knowing the ID. You could create this URL by looking at the source code of a YouTube page, but it’s much easier to automatically generate it.

One way is to save the following link as a bookmarklet by dragging it to your Links bar (in Firefox, Safari) or right-clicking and adding it to your favorites (in Internet Explorer, Opera):

youtube-bookmarklet
If you didn’t manage to add the bookmarklet, this post has more detailed instructions.

When you want to download a YouTube video, just click on the bookmarklet.
youtube-download
After clicking on the download link, YouTube will try to save the video as “video.mp4″. You should enter a more appropriate name if you want to find the video later.youtube-save-as-mp4
Having to click on the bookmarklet is annoying, so this Greasemonkey script is a better alternative because it adds the download link automatically. It requires the Greasemonkey extension for Firefox or a similar plug-in for userscripts. Opera has built-in support for userscripts, so you only need to go to Tools > Preferences > Advanced > Content > JavaScript options, select the directory where you will put your script and copy the script to that directory.

YouTube’s MP4 files have a higher resolution, stereo sound and can be played with applications like VLC, MPlayer, iTunes, QuickTime. Not all YouTube videos can be downloaded as MP4 files and the fallback format is FLV.

Note that YouTube’s terms of use require you “not to access User Submissions or YouTube Content through any technology or means other than the video playback pages of the Website itself, the YouTube Embeddable Player, or other explicitly authorized means YouTube may designate,” so these scripts could break YouTube’s policies. The scripts only download files that are used by YouTube’s player, so you may also find the videos in your browser’s cache.

Update: You no longer have to right-click and select “save link as” because YouTube sends the right MIME type. Just click on the download link.

Update 2: If the video is available in HD, the bookmarklet and the script download the HD version. Thanks, pepemosca!

Share

Related posts:

  1. YouTube Tests Higher Resolution Videos
  2. FREE Download Audio/Video: Emaan Ramadan by Dr Aamir Liaquat Hussain
  3. Read Docx, Doc, HTML, HTM & Txt Files with Word Reader
  4. YouTube blocked in Pakistan
  5. Watch,Download & Listen Atif Aslam reciting Naat in the condition of Ehraam at Hajj 2009

You can leave a response, or trackback from your own site.

9 Responses to “Download YouTube Videos as MP4 Files”

  1. [...] is the original post: Download YouTube Videos as MP4 Files This entry was posted in youtube and tagged browser, downloaded-as-mp4, flv, only-get, quality, [...]

  2. patrack says:

    Bywifi Video Downloader is a free program for p2p accelerating, downloading and transcoding video stream from all video websites, such as Youtube, Dailymotion, Metacafe, MySpace, Yahoo, etc. The program has some features:

    1. P2P Accelerating:With P2SP (peer-to-server-and-peer), it speeds up downloading of video streaming. Its better algorithms have accelerated video downloading by more than 3–5 times.
    2. Downloading: With automatically flash stream detection, video contents on many websites can be downloaded easily and free.
    3. Transcoding: Videos can be transcoded into many formats supporting any mobile phones and PDAs, such as Nokia, iPhone, SamSung, iPad, iPod, and PSP.

  3. Maximo says:

    Pixel camera with a Schneider Krauznach lens, focus, manual focus, Xenon flash, video capture and TV quality video playback.

  4. Zahid says:

    It’s really good to see how download Youtube video and can see them offline in my computer. it was really a new thing for me and I will use this to download video now to onward
    Thanks

  5. getvideo says:

    You can download youtube video at http://getvideo.comxa.com.
    It supports HD version.

  6. [...] Videos? There are several ways offered by different sites and one of the way I already mentioned of Downloading Youtube Video in mp4 format. You can Download these Video from Read Player ver. 11.0.06 and if you don’t have Real Player [...]

  7. Horisombibe says:

    It’s better to leave Windows XP and just upgrade your laptop. It’s much better. Besides, Windows XP is way better then Windows Me. Windows Me is obsolete and many programs that can run with XP, can’t run with Me.

    ——————-

  8. Songs from Compact, functioning of online?Year your vehicle, strong argument in.?Maths Wiz is, do so look.Manpower requirement All youtube music videos free, nervous Anything higher av de mer.Out and not, later on You.,

  9. Pepe says:

    There is a neat mobile app that facilitates this manual process. Search youtube for a media item, select the appropriate video format, then download and save it directly to your mobile. The app is called MFL – Mobile File Loader and will be released at 22th November 2009 as open source project on sourceforge: https://sourceforge.net/projects/mfl/

Leave a Reply