youtube-dl is a Python based small command-line tool that allows to download videos from YouTube.com, Dailymotion, Google Video, Photobucket, Facebook, Yahoo, Metacafe, Depositfiles and few more similar sites. It written in pygtk and requires Python interpreter to run this program, it’s not platform restricted. It should run on any Unix, Windows or in Mac OS X based systems.
Recently, youtube-dl added video download support for 17 new websites: brightcove.com, auengine.com, RingTV, instagram.com, Jukebox, 3sat, CSpan, Statigr.am, traileraddict.com, hotnewhiphop.com, wat.tv, tu.tv, gamespot.com, tudou.com, Wimp.com, archive.org and break.com
youtube-dl also allows to choose specific avialable video quality format to download or let the program itself automatically download higher quality video from the site. It also has supports for user specific playlist downloads, options to add custom or original title to the downloaded video file. proxy support and many more.
Install YouTube-DL in RHEL/CentOS and Fedora
The youtube-dl program can be installed by enabling epel repository under your systems. Once enabled, you can install using ‘yum‘ package manager tool as shown.
# yum install youtube-dl
Install YouTube-DL in Ubuntu/Linux Mint and Debian
Ubuntu users can download and install latest youtube-dl version from the webupd8 PPA as shown.
$ sudo add-apt-repository ppa:nilarimogard/webupd8 $ sudo apt-get update $ sudo apt-get install youtube-dl
Youtube-dl itself can be updated to the latest version using the following command.
# youtube-dl -U
How to Use YouTube-DL to Download Videos
To download a video file, simply run the following command. Where “VIDEO_URL” is the url of the video that you want to download.
# youtube-dl http://www.youtube.com/watch?v=vKtwZmhX0lw [youtube] Setting language [youtube] VMkkaQZAK3c: Downloading video webpage [youtube] VMkkaQZAK3c: Downloading video info webpage [youtube] VMkkaQZAK3c: Extracting video information [download] Destination: Natural Skin Whitening Methods-VMkkaQZAK3c.mp4 [download] 15.3% of 218.88MiB at 968.72KiB/s ETA 03:16
To download a video in availabe file formats, use option “–all-formats” with the command.
# youtube-dl –all-formats http://www.youtube.com/watch?v=vKtwZmhX0lw [youtube] Setting language [youtube] VMkkaQZAK3c: Downloading video webpage [youtube] VMkkaQZAK3c: Downloading video info webpage [youtube] VMkkaQZAK3c: Extracting video information Available formats: 37 : mp4 [1080x1920] 46 : webm [1080x1920] 22 : mp4 [720x1280] 45 : webm [720x1280] 35 : flv [480x854] 44 : webm [480x854] 34 : flv [360x640] 18 : mp4 [360x640] 43 : webm [360x640] 5 : flv [240x400] 17 : mp4 [144x176]
To download a preferred file format, use the option ‘-f’ (video format code). For example, I would like to download flv format, So I use format code as ‘34‘ as shown below.
# youtube-dl -f 34 http://www.youtube.com/watch?v=vKtwZmhX0lw [youtube] Setting language [youtube] VMkkaQZAK3c: Downloading video webpage [youtube] VMkkaQZAK3c: Downloading video info webpage [youtube] VMkkaQZAK3c: Extracting video information [download] Destination: Natural Skin Whitening Methods-VMkkaQZAK3c.flv [download] 16.9% of 32.57MiB at 916.81KiB/s ETA 00:30
To download a list of video files, create a file and place all the YouTube links that you wish to download.
# youtube-dl -a youtube_links.txt
Type the following command in a terminal to list all the avialable options.
# man youtube-dl
For other distributions, youtube-dl can be downloaded from the youtube-dl download page.
Latest posts by Ravi Saive (see all)
- 10 Useful Free Linux eBooks for Newbies and Administrators - December 9, 2013
- TeamViewer 9 Released – Install on RHEL/CentOS/Fedora and Debian/Ubuntu - December 8, 2013
- CentOS 6.5 Released – Upgrade from CentOS 6.x to CentOS 6.5 - December 2, 2013
Linux Services & Free WordPress Setup
Our post is simply ‘DIY’ aka ‘Do It Yourself, still you may find difficulties and want us to help you out. We offer wide range of Linux and Web Hosting Solutions at fair minimum rates. Please submit your orders by Clicking Here.