This content originally appeared on DEV Community and was authored by vindianadoan
Just documenting a quick note for me to refer back later.
Problem
When I was trying to check the AWS CLI version on my terminal, I get this warning in return:
which made me go: "Hang on, pretty sure I have anaconda installed".
It must be because when I was installing anaconda, I didn't pick the setting so that Python is added to the environment.
How to Fix It
Method 1: Run Command Prompt as Administrator:
Type the following commands, substituting the path to your Anaconda Python:
assoc .py=Python.File
ftype Python.File="C:\Users\YourName\anaconda3\python.exe" "%1" %*
These commands tell Windows to associate .py with a “Python.File” type, and then map “Python.File” to your Anaconda Python executable.
Method 2: Use the Windows Default Apps Settings (No Admin Required):
- Open Settings → Apps → Default apps.
- Click Choose default apps by file type and scroll to .py.
- Select the current default app (or “No default”) and browse to your Python interpreter (e.g. C:\Users\YourName\anaconda3\python.exe).
Now it's gone.
This content originally appeared on DEV Community and was authored by vindianadoan

vindianadoan | Sciencx (2025-03-12T01:42:52+00:00) Setting anaconda Python as the default. Retrieved from https://www.scien.cx/2025/03/12/setting-anaconda-python-as-the-default/
Please log in to upload a file.
There are no updates yet.
Click the Upload button above to add an update.