Download Any Youtube Video with 3 lines of code using python - @ahmadhassan
utopian-io·@ahmadhassan·
0.000 HBDDownload Any Youtube Video with 3 lines of code using python - @ahmadhassan
<html><center> <h1>Download Any Youtube Video with 3 lines of code using python - @ahmadhassan</h1> <blockquote>Today i am going to show a simple and fast way to download any youtube video. This is just beginning method. I will share upgrade version later.</blockquote> <blockquote>I will also share the way to download a complete YouTube playlist or channel's videos at once. </blockquote> <p>Let starts:</p> <ol> <li>Open a browser window and navigate to the <a href="https://www.python.org/downloads/windows/">Download page for Windows</a> at <a href="https://www.python.org/">python.org </a>and download the latest version into your laptop/computer.<br> </li> <li>Start the installer and install the software as like others. must select the add to path option.<br> https://cdn.steemitimages.com/DQmb493zAtyHRycJHGkpgjG3uwy1KbfDBeSK9akhnaHEni3/Capture.PNG<br> </li> <li>open cmd and write python (if you see like image. python is successfully installed)<br> https://cdn.steemitimages.com/DQmVny85Xo4tAvjYhoubEdSGbutDtWtK9SeoHgHSvUQyqoG/2.PNG<br> </li> <li>write exit() and came out from python.<br> </li> <li>write pip install pytube (see below image)<br> https://cdn.steemitimages.com/DQmPgXVuggKJ9RteLrKtxsqNBH38Gc1UwBi6ZQs7YbCVx4C/3.PNG<br> </li> <li>Make a folder name youtube and with any other name which you like. <br> </li> <li>Make a yt.py file inside folder.<br> https://cdn.steemitimages.com/DQmX3gQSKqkfTfSWpjt4EZXnVANZV2wGcyNPTQYoo2wmw3a/1.PNG<br> </li> <li>Open the file and cope paste below</li> </ol> <blockquote>from pytube import YouTube<br> videolink = "youtube video link "<br> yt = YouTube(videolink).streams.first()<br> print("Video has been Downloaded Successfully...")<br> https://cdn.steemitimages.com/DQmShooGB3SpTXZN7qYbJtNaZNMPwPWQ6Rj8ALnNYzUmio8/4.PNG<br> </blockquote> <p> 9. Open cmd in folder location. </p> <p>https://cdn.steemitimages.com/DQme2qjKcCvXuzXZoZNvZJUzLexH9NJRMWYHH59PSFBrNqQ/5.PNG</p> <blockquote>Type python yt.py (See figure)</blockquote> <p><br> https://cdn.steemitimages.com/DQmPFzATbw7uFTcV6Qjvze6D8GgCVq9EC6iteKUsiDy9vDL/6.PNG</p> <h2> Video Has been downloaded Successfully.,,,,, </h2> <blockquote>Note: .stream.first() is used for download high mp4 resolution. i will describe further with more efficient script in next story if you support me. </blockquote> <p> ========================================================= </p> <p>https://steemitimages.com/0x0/https://steemitimages.com/DQmYfKYGX2M8Qc8nNUi6TqUzHKoeLmafZ6PVBMjt7wjXe5R/99.gif </p> <p> Thanks for reading and always welcome your suggestions :) ========================================================= </p> </center></html>