Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
youtube-dl for downloading pluralsight videos

Downloading Videos from Pluralsight

Disclaimer

Pluralsight do not permit users to download their videos.
If you are an user of pluralsight you have agreed with their ToS,
and are thusly refrained from doing so.
Use this knowledge at your own risk.

youtube-dl for Windows

youtube-dl will allow you to download entire video series just by pasting in the link to the course. This includes english subtitles where applicable.

1. Download youtube-dl

You can get it here from their official web-site.

2. Create a bat script file

We need to create bat script that will store all the information we need to quickly and easily download videos from pluralsight. Create a new file and name it 'pluralsight.bat'. Put it in the same folder as youtube-dl.exe (from step 1).

3. Paste in the script in the file

for %%a in (%*) do (
.\youtube-dl.exe ^
--username YOUR-USERNAME-HERE ^
--password YOUR-PASSWORD-HERE ^
%%a ^
-o "C:/Users/YOUR-USERNAME-HERE/Videos/Pluralsight/%%(playlist)s/%%(chapter_number)02d - %%(chapter)s/%%(playlist_index)02d - %%(title)s.%%(ext)s" ^ --sleep-interval 35 ^
--max-sleep-interval 120 ^
--sub-lang en ^
--sub-format srt ^
--write-sub
)

  1. Remember to add your own username, password and the path to where you want the videos to be stored. Replace YOUR-USERNAME-HERE, YOUR-PASSWORD-HERE and YOUR-NAME-HERE.
  2. If you wish to change the formatting of the output video files, you can learn more about it here.

4. Begin downloading videos

In order to run the scripts, you need to open up a command prompt or Windows PowerShell. Navigate to the folder you have the script and youtube-dl.exe. Hold left-shift and right mouse click in the folder, and select 'Open PowerShell Window here' or the 'Command Prompt' equivalent.

All you have to do now in order to download pluralsight videos, is to run:

.\pluralsight.bat [URL-HERE]

You can also add multiple URLs, separated by a space:

.\pluralsight.bat [URL1] [URL2] [URL3]

If you open up a text editor (for copy/paste), you can also prepare all your URL in a similar fashion:

pluralsight-dl ^
[URL1] ^
[URL2] ^
[URL3]

URL is usually formatted similar to https://app.pluralsight.com/library/courses/some-course-name


youtube-dl for Linux

youtube-dl will allow you to download entire video series just by pasting in the link to the course. This includes english subtitles where applicable.

1. Download youtube-dl

You can get it here from their official web-site.

2. Create the bash script file

We are going to create bash script that will store all the information we need to quickly and easily download videos from pluralsight. Make sure you save it inside /bin, as it will allow us to run the 'pluralsight-dl' command from anywhere.

sudo touch /usr/local/bin/pluralsight-dl
sudo chmod a+rx /usr/local/bin/pluralsight-dl
sudo nano /usr/local/bin/pluralsight-dl

3. Paste in the script

#!/bin/bash
for i in "$@";
do

youtube-dl \
--username YOUR-USERNAME-HERE \
--password YOUR-PASSWORD-HERE \
"$i" \
-o "/home/YOUR-USERNAME-HERE/Videos/%(playlist)s/%(chapter_number)02d - %(chapter)s/%(playlist_index)02d - %(title)s.%(ext)s" \
--sleep-interval 35 \
--max-sleep-interval 120 \
--sub-lang en \
--sub-format srt \
--write-sub

done

  1. Remember to add your own username, password and the path to where you want the videos to be stored. Replace YOUR-USERNAME-HERE, YOUR-PASSWORD-HERE and YOUR-NAME-HERE.
  2. If you wish to change the formatting of the output video files, you can learn more about it here.

3. Begin downloading videos

All you have to do now in order to download pluralsight videos, is to run:

pluralsight-dl [URL-HERE]

You can also add multiple URLs, separated by a space:

pluralsight-dl [URL1] [URL2] [URL3]

If you open up a text editor (for copy/paste), you can also prepare all your URL in a similar fashion:

pluralsight-dl \
[URL1] \
[URL2] \
[URL3]

URL is usually formatted similar to https://app.pluralsight.com/library/courses/some-course-name

@tonoy30
Copy link

tonoy30 commented Apr 10, 2021

@abgebrekirstos try adding

-i, --ignore-errors                  Continue on download errors, for
                                    example to skip unavailable videos in a
                                    playlist

@RobertHernandezArenas
Copy link

RobertHernandezArenas commented Apr 10, 2021

By attaching cookies and user-agnet it works for me.

for %%a in (%*) do (
youtube-dl --verbose ^
--cookies "./cookies.txt" ^
--user-agent "Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:72.0) Gecko/20100101 Firefox/72.0" ^
%%a ^
-o "D:/Tutorials/Pluralsight/%%(playlist)s/%%(chapter_number)02d - %%(chapter)s/%%(playlist_index)02d - %%(title)s.%%(ext)s" ^ --sleep-interval 35 ^
--max-sleep-interval 120 ^
--sub-lang en ^
--sub-format srt ^
--write-sub
)

There are a number of cookies in pluralsight, can you please tell which one to use and how?

There is a chrome extension called " Get Cookies.txt", when you have already install it you have to do log in in pluralsight and use this extension, export file in root folder youtube-dl , that's all bro

@judhenaoma
Copy link

judhenaoma commented Apr 11, 2021

Someone can help me to download videos from pluralsight, i have tried pluradl.py and the last post of @tonoy30, its dont work for me. Please...

@hazem1987
Copy link

hazem1987 commented Apr 14, 2021

Hello All ,

does anyone knows how to start from specific videos ? i want to download let's say videos from 10 :20 and so on

@mehroosali
Copy link

mehroosali commented Apr 25, 2021

can anybody share their latest working script?

@shrishyl47
Copy link

shrishyl47 commented Apr 28, 2021

By attaching cookies and user-agnet it works for me.

for %%a in (%*) do (
youtube-dl --verbose ^
--cookies "./cookies.txt" ^
--user-agent "Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:72.0) Gecko/20100101 Firefox/72.0" ^
%%a ^
-o "D:/Tutorials/Pluralsight/%%(playlist)s/%%(chapter_number)02d - %%(chapter)s/%%(playlist_index)02d - %%(title)s.%%(ext)s" ^ --sleep-interval 35 ^
--max-sleep-interval 120 ^
--sub-lang en ^
--sub-format srt ^
--write-sub
)

There are a number of cookies in pluralsight, can you please tell which one to use and how?

There is a chrome extension called " Get Cookies.txt", when you have already install it you have to do log in in pluralsight and use this extension, export file in root folder youtube-dl , that's all bro

This works. Thanks.

@BUBUsnet
Copy link

BUBUsnet commented Apr 28, 2021

By attaching cookies and user-agnet it works for me.

for %%a in (%*) do (
youtube-dl --verbose ^
--cookies "./cookies.txt" ^
--user-agent "Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:72.0) Gecko/20100101 Firefox/72.0" ^
%%a ^
-o "D:/Tutorials/Pluralsight/%%(playlist)s/%%(chapter_number)02d - %%(chapter)s/%%(playlist_index)02d - %%(title)s.%%(ext)s" ^
--sleep-interval 150 ^
--max-sleep-interval 200 ^
--limit-rate 1M ^
--sub-lang en ^
--sub-format srt ^
--write-sub
)

For exporting cookies you can use this extension: Get cookies.txt

Thx. For linux users:

!/bin/bash
for i in "$@";
do

youtube-dl \
--cookies "./cookies.txt" \
--user-agent "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/90.0.4430.93 Safari/537.36" \
"$i" \
-o "/tmp/Videos/%(playlist)s/%(chapter_number)02d - %(chapter)s/%(playlist_index)02d - %(title)s.%(ext)s" \
--sleep-interval 35 \
--max-sleep-interval 120 \
--sub-lang en \
--sub-format srt \
--write-sub

done

You should change the download folder.

@Jafolayan1
Copy link

Jafolayan1 commented May 26, 2021

I'm getting this error after i followed the steps above
./pluralsight.sh https://app.pluralsight.com/library/courses/designing-complexity-aws

[pluralsight:course] designing-complexity-aws: Downloading JSON metadata
[download] Downloading playlist: Designing for Complexity on AWS
[pluralsight:course] playlist Designing for Complexity on AWS: Collected 28 video ids (downloading 28 of them)
[download] Downloading video 1 of 28
[pluralsight] Downloading login page
[pluralsight] Logging in
ERROR: Unable to download webpage: HTTP Error 403: Forbidden (caused by HTTPError()); please report this issue on https://yt-dl.org/bug . Make sure you are using the latest version; type youtube-dl -U to update. Be sure to call youtube-dl with the --verbose flag and include its complete output.

Please, where you able to fix this ??

@ivanskodje
Copy link
Author

ivanskodje commented May 26, 2021

I'm getting this error after i followed the steps above
./pluralsight.sh https://app.pluralsight.com/library/courses/designing-complexity-aws
[pluralsight:course] designing-complexity-aws: Downloading JSON metadata
[download] Downloading playlist: Designing for Complexity on AWS
[pluralsight:course] playlist Designing for Complexity on AWS: Collected 28 video ids (downloading 28 of them)
[download] Downloading video 1 of 28
[pluralsight] Downloading login page
[pluralsight] Logging in
ERROR: Unable to download webpage: HTTP Error 403: Forbidden (caused by HTTPError()); please report this issue on https://yt-dl.org/bug . Make sure you are using the latest version; type youtube-dl -U to update. Be sure to call youtube-dl with the --verbose flag and include its complete output.

Please, where you able to fix this ??

People report that they have increase their security, and that you may have to add cookies. Read the above comments and see if it helps you.
Because I no longer have access to pluralsight (because I am not paying for it), I am unable to test this myself.

@Jafolayan1
Copy link

Jafolayan1 commented May 26, 2021

I'm getting this error after i followed the steps above
./pluralsight.sh https://app.pluralsight.com/library/courses/designing-complexity-aws
[pluralsight:course] designing-complexity-aws: Downloading JSON metadata
[download] Downloading playlist: Designing for Complexity on AWS
[pluralsight:course] playlist Designing for Complexity on AWS: Collected 28 video ids (downloading 28 of them)
[download] Downloading video 1 of 28
[pluralsight] Downloading login page
[pluralsight] Logging in
ERROR: Unable to download webpage: HTTP Error 403: Forbidden (caused by HTTPError()); please report this issue on https://yt-dl.org/bug . Make sure you are using the latest version; type youtube-dl -U to update. Be sure to call youtube-dl with the --verbose flag and include its complete output.

Please, where you able to fix this ??

People report that they have increase their security, and that you may have to add cookies. Read the above comments and see if it helps you.
Because I no longer have access to pluralsight (because I am not paying for it), I am unable to test this myself.

Okay, using VPN fixed it. Thanks

@truongquoc
Copy link

truongquoc commented Jun 1, 2021

--add-header not -add-header

Seems your account has been blocked

No, I think they have just tightened their security slightly. I was getting the 403 error until I added the following line to my config file:

-add-header Referer:https://app.pluralsight.com/library/courses/

Thanks for your help. It works for me

@duracotton
Copy link

duracotton commented Jun 9, 2021

That did not help in my case.
When providing a user agent it was working:
--user-agent "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/89.0.4389.114 Safari/537.36"

@shanks-abhi
Copy link

shanks-abhi commented Jun 22, 2021

With help from the comments , I managed to atleast start downloading the videos using cookies.
Everything was going fine in my case until I got blocked I violated their TOS.I got an email for the same. I guess Pluralsight is onto all methods of downloading the videos.

Anyone still able to download the videos without getting blocked? Please let me know if you folks have figured out a way around this

Update : Got my account back after changing password and exchanging mails with pluralsight IT. If anyone is still able to download videos without getting banned, do help in that regard.
PLural

@duracotton
Copy link

duracotton commented Jun 22, 2021

@shanks-abhi which sleep intervals etc. did you use?

@shanks-abhi
Copy link

shanks-abhi commented Jun 22, 2021

@duracotton I didnt change the intervals in the original code that we were asked to copy and paste to make the bat file. So, sleep interval of 35 and max sleep interval of 120

@duracotton
Copy link

duracotton commented Jun 22, 2021

@shanks-abhi: That's maybe the reason your account got blocked. Some people recommended something like:
--min-sleep-interval 100 --max-sleep-interval 120 --rate-limit 254976

so a varying (higher) sleep interval plus throttling of download speed (bytes per second) down to 250 kByte/s. The speed throttling is just a guess and the rate is made up by me (who knows if they take the downloadspeed as indicator) but who cares if it takes a bit longer...

@shanks-abhi
Copy link

shanks-abhi commented Jun 22, 2021

Ok,Thanks. I will try increasing the interval times. Is it working for you? Have you tried downloading any plural sight videos? If you have a working code,Could you pls share?

@duracotton
Copy link

duracotton commented Jun 22, 2021

@shanks-abhi: Yes I downloaded 4-5 courses in a row. I used the following .bat:

youtube-dl --output "E:\Downloads\Pluralsight%%(playlist)s%%(chapter_number)s - %%(chapter)s%%(playlist_index)s - %%(title)s.%%(ext)s" --cookie "pluralsight_cookie.txt" --no-overwrites --no-post-overwrites --verbose --write-sub --min-sleep-interval 100 --max-sleep-interval 120 --rate-limit 254976 --add-header Referer:"https://app.pluralsight.com/library/courses" --user-agent "Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:88.0) Gecko/20100101 Firefox/88.0" --batch-file=batch_filelist_pluralsight.txt
pause

-where "pluralsight_cookie.txt" is the exported plural sight cookie from your browser (see info here: ytdl-org/youtube-dl#26331 (comment)) instead of using your credentials directly.
-where batch_filelist_pluralsight.txt is a textfile which contains the courses (links), one link per row, e.g.:
https://app.pluralsight.com/library/courses/fundamental-cloud-concepts-aws
https://app.pluralsight.com/library/courses/understanding-aws-core-services
[...]
-I also use a real browser user agent

@shanks-abhi
Copy link

shanks-abhi commented Jun 22, 2021

Thanks for sharing @duracotton .. I will try with what you have shared with the modifications you mentioned. Let's hope I don't get banned a second time.

@pomtom
Copy link

pomtom commented Jul 28, 2021

[download] Downloading video 1 of 40
[pluralsight] Downloading login page
ERROR: Unable to download webpage: HTTP Error 403: Forbidden (caused by HTTPError()); please report this issue on https://yt-dl.org/bug . Make sure you are using the latest version; type youtube-dl -U to update. Be sure to call youtube-dl with the --verbose flag and include its complete output.

@pomtom
Copy link

pomtom commented Jul 28, 2021

[debug] Encodings: locale cp1252, fs mbcs, out cp65001, pref cp1252
[debug] youtube-dl version 2021.06.06
[debug] Python version 3.4.4 (CPython) - Windows-10-10.0.18362
[debug] exe versions: none
[debug] Proxy map: {}
[pluralsight:course] microsoft-azure-authentication-scenarios-developers: Downloading JSON metadata
[download] Downloading playlist: Microsoft Azure Authentication Scenarios for Developers
[pluralsight:course] playlist Microsoft Azure Authentication Scenarios for Developers: Collected 40 video ids (downloading 40 of them)
[download] Downloading video 1 of 40
[pluralsight] Downloading login page
ERROR: Unable to download webpage: HTTP Error 403: Forbidden (caused by HTTPError()); please report this issue on https://yt-dl.org/bug . Make sure you are using the latest version; type youtube-dl -U to update. Be sure to call youtube-dl with the --verbose flag and include its complete output.
File "C:\Users\dst\AppData\Roaming\Build archive\youtube-dl\ytdl-org\tmpkqxnwl31\build\youtube_dl\extractor\common.py", line 634, in _request_webpage
File "C:\Users\dst\AppData\Roaming\Build archive\youtube-dl\ytdl-org\tmpkqxnwl31\build\youtube_dl\YoutubeDL.py", line 2288, in urlopen
File "C:\Python\Python34\lib\urllib\request.py", line 470, in open
File "C:\Python\Python34\lib\urllib\request.py", line 580, in http_response
File "C:\Python\Python34\lib\urllib\request.py", line 508, in error
File "C:\Python\Python34\lib\urllib\request.py", line 442, in _call_chain
File "C:\Python\Python34\lib\urllib\request.py", line 588, in http_error_default

@pratikbin
Copy link

pratikbin commented Aug 19, 2021

@xseman
Copy link

xseman commented Sep 3, 2021

Their system very quickly detects youtube-dl downloads, it is really difficult to debug which process will start the automatic block system.

I think they monitor some kind of web actions and map the current video buffering to the session with web actions.

Reply from their IT support email when I required what triggers the system.

Unfortunately, for Security reasons, we are unable to provide specific details on the account blocking reason. 

However, we can provide a list of the most common causes for this type of blocking: 

- Unusual usage, such as excessive skipping through video content
- The use of media scraping software or browser extensions that download video content outside of the approved offline player
- Generalized/generic account information (ensure that your account information reflects individual ownership, such as a valid first and last name)
- Having an unusual number of authorized devices (you may review Devices listed in your Account Settings to remove any that are not tied to the individual account holder, and any duplicate devices)
- Unintended usage via malware

@pratikbin
Copy link

pratikbin commented Sep 4, 2021

Their system very quickly detects youtube-dl downloads, it is really difficult to debug which process will start the automatic block system.

I think they monitor some kind of web actions and map the current video buffering to the session with web actions.

Reply from their IT support email when I required what triggers the system.

Unfortunately, for Security reasons, we are unable to provide specific details on the account blocking reason. 

However, we can provide a list of the most common causes for this type of blocking: 

- Unusual usage, such as excessive skipping through video content
- The use of media scraping software or browser extensions that download video content outside of the approved offline player
- Generalized/generic account information (ensure that your account information reflects individual ownership, such as a valid first and last name)
- Having an unusual number of authorized devices (you may review Devices listed in your Account Settings to remove any that are not tied to the individual account holder, and any duplicate devices)
- Unintended usage via malware

Been there. It's very quick

@Nipponshin
Copy link

Nipponshin commented Sep 20, 2021

I can confirm that even after following all suggestions their system blocked me. It just annoys me that I am informed of the access for a year "after" I have already paid for one of their bundles from HB...

I have reset my password and got access again. They mentioned that if this behaviour is detected 3 times, your account gets permanently blocked. If anyone was able to download the Kubernetes bundle on HB and can share it via torrent I would greatly appreciate it!

@Lucas-fr-fr
Copy link

Lucas-fr-fr commented Oct 14, 2021

Hello,
Someone can help me with my error ?
I'm on windows powershell :

PS C:\Windows\System32> .\pluralsight.bat https://app.pluralsight.com/library/courses/sap-business-warehouse-query-fundamentals/table-of-contents

C:\Windows\System32>for %a in (https://app.pluralsight.com/library/courses/sap-business-warehouse-query-fundamentals/table-of-contents) do (.\youtube-dl.exe --username usermane --password password %a -o "C:/Users/Lucas/Videos/Pluralsight/%(playlist)s/%(chapter_number)02d - %(chapter)s/%(playlist_index)02d - %(title)s.%(ext)s" --sleep-interval 35 --max-sleep-interval 120 --sub-lang en --sub-format srt --write-sub )

C:\Windows\System32>(.\youtube-dl.exe --username username --password password https://app.pluralsight.com/library/courses/sap-business-warehouse-query-fundamentals/table-of-contents -o "C:/Users/Lucas/Videos/Pluralsight/%(playlist)s/%(chapter_number)02d - %(chapter)s/%(playlist_index)02d - %(title)s.%(ext)s" --sleep-interval 35 --max-sleep-interval 120 --sub-lang en --sub-format srt --write-sub )
Fatal Python error: Py_Initialize: unable to load the file system codec
ImportError: No module named 'encodings'

Current thread 0x00003808 (most recent call first):

@anumomin
Copy link

anumomin commented Nov 16, 2021

anyone can't download videos see below
Working as of 7-Aug-2021
https://gist.github.com/mshaikhcool/54c11eeb2e452297ab49c27b2e28e287

Both URLs are not working,,
Can someone please confirm if pluralsight downloading is still working?

@elgydium
Copy link

elgydium commented Jan 7, 2022

It ain't working for me either ERROR: '[https://app.pluralsight...table-of-contents] is not a valid URL.

@goombah88
Copy link

goombah88 commented Jul 25, 2022

Or this error...

ERROR: core-python-implementing-iterators-iterables-collections: Failed to parse JSON (caused by ValueError('No JSON object could be decoded',)); please report this issue on https://yt-dl.org/bug . Make sure you are using the latest version; type youtube-dl -U to update. Be sure to call youtube-dl with the --verbose flag and include its complete output.

@Shakil-Shahadat
Copy link

Shakil-Shahadat commented Jul 25, 2022

@goombah88 use yt-dlp.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment