I am trying to download a playlist using youtube -dl but getting an error.


youtube-dl --playlist-start 1 https://www.youtube.com/playlist?list=PL8B24C31197EC371C


    [youtube:playlist] PL8B24C31197EC371C: Downloading page #1
ERROR: Unable to download webpage: <urlopen error [Errno 8] _ssl.c:510: EOF occurred in violation of protocol>

What should i do?

  • Have you verified that you are using the most recent version of youtube-dl?
    – user
    Jun 27, 2016 at 14:34
  • @MichaelKjörling Yes. I have checked it.
    – rohit15079
    Jun 27, 2016 at 14:35
  • @rohit15079 I can't reproduce your error; I was able to download the playlist. I installed youtube-dl using pip in a virtualenv for both Python 2 and 3 on a Ubuntu 16.04 machine.
    – edwinksl
    Jun 27, 2016 at 14:43
  • @edwinksl how to do that?
    – rohit15079
    Jun 27, 2016 at 14:45
  • @rohit15079 There are plenty of resources for learning how to install and use pip and virtualenv. There isn't enough space in a comment to show you how to do that.
    – edwinksl
    Jun 27, 2016 at 14:48

1 Answer 1


My fault:

I installed youtube-dl using command : sudo apt-get install youtube-dl

What should I have done:

I should have used commands (either one):


sudo curl -L https://yt-dl.org/latest/youtube-dl -o /usr/local/bin/youtube-dl
sudo chmod a+rx /usr/local/bin/youtube-dl


sudo wget https://yt-dl.org/downloads/latest/youtube-dl -O /usr/local/bin/youtube-dl
sudo chmod a+rx /usr/local/bin/youtube-dl

I used the first one and then it worked correctly.

  • 2
    before you forget that path, you should alias it. Example: add alias youtube-dl='/usr/local/bin/youtube-dl' in your .bashrc
    – Augusto
    Jul 22, 2016 at 17:41
  • 3
    @augusto /usr/local/bin is usually in your $PATH, meaning that you don't need that alias to just run youtube-dl something from bash. Aug 11, 2017 at 10:05

Not the answer you're looking for? Browse other questions tagged .