@echo off :: 1. Safely navigate to the exact folder this batch file is sitting in cd /d "%~dp0" :: 2. Launch the app in the background and instantly close the command prompt start "" "python\pythonw.exe" -m my_package.gui