How to download and install Python Latest Version on macOS / Mac OS X

Python is a widely-used general-purpose, high-level programming language. This article will serve as a complete tutorial on How to download and install Python latest version on macOS / Mac OS X. Like Linux, macOS also comes with Python pre-installed on the system. It might be Python version 2 or some similar outdated version. To update to the latest version, we will use the Homebrew Package manager. It is one of the best and convenient methods to install Python on macOS.
To know more about Homebrew Package manager, visit here.

  • Download and install Homebrew Package Manager

    If you don’t have homebrew installed on your system, follow the steps below
    Open the Terminal Application of macOS from Application -> Utilities. Bash terminal will open where you can enter commands
    Enter following command in macOS terminal

    /usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
    

    install-python-on-mac



    Enter system password if prompted. This will install the Homebrew package Manager on your OS.
    After you see a message called “Installation Successful”. You are ready to install python version 3 on your macOS.

    install-python-on-mac-4-

  • Install Python Latest Version on macOS / macOS X

    To install python simple open Terminal app from Application -> Utilities
    and enter following command

    brew install python3

    After command processing is complete, Python’s version 3 would be installed on your mac.

    install-python-on-mac-2

    To verify the installation enter following commands in your Terminal app

    python
    pip3

    install-python-on-mac-1-

    Bingo..!! Python is installed on your computer. You can explore more about python here



My Personal Notes arrow_drop_up

Check out this Author's contributed articles.

If you like GeeksforGeeks and would like to contribute, you can also write an article using contribute.geeksforgeeks.org or mail your article to contribute@geeksforgeeks.org. See your article appearing on the GeeksforGeeks main page and help other Geeks.

Please Improve this article if you find anything incorrect by clicking on the "Improve Article" button below.


Article Tags :

Be the First to upvote.


Please write to us at contribute@geeksforgeeks.org to report any issue with the above content.