I am a big fan of Udemy and I have purchased about 13 courses off of the site (and counting) but sometimes I don’t have access to the internet on my laptop and watching videos (especially programming videos) on my Android phone which have been synced offline and being able to follow along isn’t easy or ideal.
I have found a clever and simple Python script that allows you to download your paid Udemy course videos so you can watch them on your Mac or PC offline without needing any kind of internet connection (except for the initial download).
The resulting quality appears to be about 720p, so the downloaded files are legit and watchable. The script uses the ever-versatile BeautifulSoup library for logging in, parsing the JWPlayer JSON object in the page and then creates a folder and downloads all course videos.
The Python script can be viewed and download here on Github.
Keep in mind this is against the terms of service for Udemy and could result in you losing access to your account. Course authors can actually allow videos to be downloaded, but most don’t. Be careful and be respectful. Udemy could shutdown this method of downloading videos at any time.
There is also another method which involves downloading your course videos offline on your smartphone and then installing an app that allows you to browse and download files from your phone, but there are a lot of steps required to do so. This Python script is currently the easiest way and it works really well.
Update 2020: This method still works. I had to update the repository as the original was removed.