(Last Updated On: September 25, 2018)

Would you like to download youtube videos from a web application?, ytdl-webserver is a web server application written in Node.js for downloading youtube videos. If you don’t want to use npm to run the application, the developer provides a docker image which you can use – I’m a big fan of Docker, good for isolating applications.

How to install ytdl-webserver youtube videos downloader

There are two ways to install ytdl-webserver

  1. Using npm Node.js  package manager
  2. Running ytdl-webserver inside docker

Method 1: Install ytdl-webserver using npm

You need to have Node.js and npm installed on your machine to use this method. check out our guide for installation of Node.js on Linux

How to run multiple versions of Node.js on Linux

Once you have Node.jsinstalled, download git, for cloning the project source code from Github

sudo yum install github      # CentOS
sudo apt-get install git     # Debian/Ubuntu
sudo pacman -S git           # Arch Linux and Manjaro
sudo dnf install git         # Fedora

Install ffmpeg ( Ubuntu/Debian, Fedora & Arch)

sudo apt-get install ffmpeg
sudo dnf install ffmpeg
sudo pacman -S ffmpeg

Install youtube-dl

Use python pip package installer to install youtube-dl

sudo pip install youtube-dl

Get application source code

git clone https://github.com/Algram/ytdl-webserver.git

Change your working directory to ytdl-webserver

cd ytdl-webserver

Install it by running

npm install

Then start the application

npm start

Sample output:

Method 1: Install ytdl-webserver using Docker

Running ytdl-webserver in Docker container is the quickest method to use the application to download youtube videos.

Download and Install Docker on your Linux box using our previous guide

How to install Docker CE on Ubuntu / Debian / Fedora / Arch / CentOS

When docker is installed, create a directory for storing youtube videos

mkdir ~/ytdl-webserver

Start docker container with a mapped directory

docker run  -v $HOME/ytdl-webserver:/home/app/public/temp -d \
-p 3000:3000 algram/ytdl-webserver

See screenshot below

Using ytdl-webserver to download YouTube Videos

Open the URL http://localhost:3000/ on your browser

Paste URL to YouTube video you want to download.

Wait for the application to pull Video metadata, then click Download button to download the Video.

That’s all. Enjoy using ytdl-webserver and contribute to the Project if you’re a Node guy. Enjoy your day.