How to Install Python on Mac

How to Install Python on Mac

If you intend to use our Python courses with a code editor like Visual Studio, Anaconda, Spyder, or something else, you will need to first install the Python runtime to your local computer. This short article will cover how to do this for macOS - for Windows see this article instead: How to Install Python on Windows

 

Download Python

1. Head to the Python website's download page: https://www.python.org/downloads/

2. Download a compatible version. Note that this may vary by course depending on the Python libraries used in the course. We recommend reviewing the course's information to determine the appropriate version.


Install on Mac

This section will cover installation as it applies to Mac. Windows users should follow the steps outlined in the previous section.

1. Open the package file downloaded to your computer and follow the on-screen instructions.


2. Once the installation finishes, you will get a congratulations message and can close the installation wizard.


Verifying Installation

Once the installation finishes, we'll want to verify that Python is properly installed. To do so, follow the steps below:

1. Start the Python IDLE application - Python's built-in shell for running Python files.



2. Go to File > New File from the top menu to create a new file:

 

3. In the new file, enter the following code into the editor: 
  1. print("Hello world")


4. Save the Python file
5. Select Run > Run Module from the top menu, or hit F5.



5. If Python is installed correctly, a new window should pop-up with our "Hello world" message printed!

    • Related Articles

    • How to Install Python on Windows

      If you intend to use our Python courses with a code editor like Python's build-in IDLE, Visual Studio, Anaconda, Spyder, or something else, you will need to first install the Python runtime to your local computer. This short article will cover how to ...
    • How to Install Visual Studio Code for Mac

      In this article, we'll showcase how to install Visual Studio Code (VSC), a multi-language applicable code editor, for macOS. If you'd like to install VSC for Windows, see this article instead: How to Install Visual Studio Code for Windows Installing ...
    • How to Install Visual Studio Code for Windows

      In this article, we'll showcase how to install Visual Studio Code (VSC), a multi-language applicable code editor, for Windows. If you'd like to install VSC for Mac, see this article instead: How to Install Visual Studio Code for Mac Installing VSC ...
    • How to Install Unity

      This article will cover both how to install Unity for the first time, and how to install new versions of Unity for pre-existing installations. Before installation you may wish to review Unity's system requirements. First Time Installation Only - ...
    • How to Install Blender

      In this article, we'll discuss how to install Blender, the free, 3D modeling software. Before beginning, you may wish to review Blender's system requirements. Installing Blender 1. Go to the official site of Blender at https://www.blender.org/ 2. In ...