Search code examples
pythonpyinstaller

Python into .exe


I want to convert my python file to a .exe file using pyinstaller. I have installed pyinstaller using pip install pyinstaller, but when I try use pyinstaller I get:

C:\Users\Varnith\Desktop\program>pyinstaller --onefile main.py
'pyinstaller' is not recognized as an internal or external command,
operable program or batch file.

Solution

  • The problem is pyinstaller hasn't been added to path. Make sure you installed it properly. If on Windows, try:

    pip install pyinstaller
    

    or

    py -m pip install pyinstaller
    

    Otherwise, pip3 & python3