Running into hurdles even before starting your Python journey can be disheartening, especially when the issue is as trivial as not having admin rights on your Windows machine. But don’t worry, we’ve got your back. In this post, we’ll guide you through installing Python on a Windows machine, even without admin rights.
Step 1: Downloading Python
First, you’ll need to download the Python installer:
Head over to the Python’s official downloads page.
Find the version you want to install and click on it. As a beginner, it’s recommended to download the latest version.
Remember to choose the version that corresponds to your machine’s architecture (32-bit or 64-bit).
Step 2: Run the Python Installer
Once you’ve downloaded the Python installer, it’s time to run it:
Locate the Python installer file you just downloaded.
Right-click the file and choose “Run as administrator”. If you’re not an admin, a User Account Control dialogue will pop up asking for the admin password. If you can’t provide this, simply click “No”.
This will run the installer without admin privileges.
Step 3: Customize Installation
In the Python setup window, you’ll see two installation options: “Install Now” and “Customize Installation”. Since you’re installing without admin rights, you should select “Customize Installation”.
Step 4: Customize Install Location
This is where you have to be careful. By default, Python is installed in the Program Files folder, a location that requires admin rights. To bypass this, you need to specify a different install location:
In the “Customize Python” screen, click “Next”.
In the next screen titled “Advanced Options”, check the box that says “Install for all users”. This will grey out and you can’t change it because you don’t have admin rights. That’s okay.
In the “Customize install location” field, specify a path that doesn’t require admin rights. This could be a folder in your “Documents” or “Downloads” or any location where you have write permissions.
An example path could look like this: C:\Users\YourUsername\Python39\
Step 5: Install Python
With your custom path set, click “Install” and the Python installer will begin to install Python in the specified directory.
Step 6: Verify Installation
To confirm that Python was installed correctly:
Open Command Prompt.
Type python –version and press Enter. This should display the Python version that you just installed.
If the Python version doesn’t appear, don’t panic. It simply means that Python is not in your system path, a common situation when installing without admin rights. To run Python, you’ll need to specify the full path of the python.exe file in the Command Prompt. Here’s how:
Navigate to the location where you installed Python.
Open the folder and locate python.exe.
In the address bar at the top of the window, you’ll see the full path of python.exe. Copy this.
Go back to Command Prompt and paste this path, then press Enter.
This will run Python, proving that your installation was successful!
That’s it! You’ve successfully installed Python on your Windows machine without admin rights. Now, you’re ready to start your Python programming adventure. Happy coding!