on windows:
1- make sure where is your python are installed , you can get the current path of python by using the following :
python -c "import os, sys; print(os.path.dirname(sys.executable))"
or
python3 -c "import os, sys; print(os.path.dirname(sys.executable))"
output (for example):
C:\Users\user\AppData\Local\Programs\Python\Python39
now go to that path and access the "Scripts" folder , and check if "pip.exe" or "pip3.exe" are there , if not try to use the following command to fix it and install it by cmd:
python -m ensurepip --upgrade
or
python3 -m ensurepip --upgrade
check again , if "pip.exe" or "pip3.exe" are there, if yes go to next step , if not try to reinstall python again (and click on pip checkbox in your Installation Wizard ) .
2- go to your "environment variables" ==> "system variables" and then click on "path"
and add tow paths (as you extract it above) :
C:\Users\user\AppData\Local\Programs\Python\Python39
C:\Users\user\AppData\Local\Programs\Python\Python39\Scripts
3- go to your "environment variables" ==> "user variables for 'your username' " and then click on "path" and add tow paths (as you extract it above) :
C:\Users\user\AppData\Local\Programs\Python\Python39
C:\Users\user\AppData\Local\Programs\Python\Python39\Scripts
4- close and reopen your CMD again and try to type "pip or pip3"
5- if every thing fine try to upgrade your pip version by the following command:
python -m pip install --upgrade pip
or
python -m pip install --upgrade pip --user
done.
i hope this helpful .