Installing Python on Windows
Installing the files is only one part of the process.
Why zip Setup Matters
This guide focuses on installing the zip command on Windows through the GnuWin32 project. Windows does not include the zip command by default, so the command must first be downloaded and installed. After installation, Windows must also be told where to find the executable. That second part is handled by the system PATH environment variable.
From Download to Installed Files
The installation process has a simple sequence. Start at the GnuWin32 project page, download the zip package, and install it. The installation should place the command-line files in the GnuWin32 installation directory. The directory used in this guide is C:\Program Files\GnuWin32\bin. The executable that you will later check for is zip.exe.
- 1Open the GnuWin32 project page.
- 2Download the zip package.
- 3Install the package using the GnuWin32 installation process.
- 4Use File Explorer to check the directory C:\Program Files\GnuWin32\bin.
- 5Confirm that
zip.exeis present in that directory.
How PATH Finds zip
The system PATH is a semicolon-separated list of directories. When you type a command, Windows searches those directories to locate an executable. Installing zip.exe in the GnuWin32 bin directory does not by itself tell Windows to search that directory. Adding C:\Program Files\GnuWin32\bin to the system PATH supplies that missing location.
- 1Open the Environment Variables dialog.
- 2Add C:\Program Files\GnuWin32\bin to the system PATH environment variable.
- 3Apply the change.
- 4Close the current command prompt window.
- 5Open a new command prompt window so the PATH change takes effect.
Checking the Installation
After installing the package, adding the bin directory to PATH, and opening a new command prompt, verify that Windows recognizes the command. Type zip --version. A successful installation produces output showing the zip version number and other information. This confirms that the command is available through the current command prompt.
Successful output shows the zip version number and other information. An unsuccessful check shows an error stating that zip is not recognized as an internal or external command.What do you think happens?
You installed zip.exe, added the GnuWin32 bin directory to PATH, and then ran zip --version in the command prompt that was already open. What is the most likely next step if the command is not recognized?
Reveal answer
Close that command prompt and open a new one
The PATH change takes effect in a new command prompt window. After reopening it, run zip --version again.
Troubleshooting a Missing Command
Common mistake Checking zip in the same command prompt that was open before PATH was changed.
What it looks likeThe PATH entry was added, but the old command prompt still reports that zip is not recognized.
Why it failsThe source instructions state that the command prompt must be closed and reopened for PATH changes to take effect.
Do this insteadOpen a new command prompt window and run zip --version again.
Common mistake Adding an incorrect directory to PATH.
What it looks likeThe PATH entry contains a typo or points somewhere other than C:\Program Files\GnuWin32\bin.
Why it failsWindows searches the directories listed in PATH. If the correct GnuWin32 bin directory is not listed, it cannot locate
zip.exethrough PATH.Do this insteadOpen the Environment Variables dialog and verify that the entry is exactly C:\Program Files\GnuWin32\bin.
Common mistake Assuming installation completed without checking for zip.exe.
What it looks likeThe command is not recognized, but the installed directory has not been inspected.
Why it failsThe installation may not have completed successfully or the files may not have been extracted correctly.
Do this insteadUse File Explorer to navigate to C:\Program Files\GnuWin32\bin and confirm that zip.exe is present.
Common mistake Ignoring the terminal application being used.
What it looks likeThe command works differently in a terminal application such as PowerShell than in the standard Command Prompt.
Why it failsThe source notes that a different terminal application might have its own PATH configuration separate from the standard Command Prompt.
Do this insteadCheck the PATH configuration for the terminal application you are using.
- 1Confirm that
zip.exeexists in C:\Program Files\GnuWin32\bin. - 2Check the PATH entry for spelling and the correct directory.
- 3Make sure you opened a new command prompt after changing PATH.
- 4Check whether your terminal application uses a separate PATH configuration.
- 5If the problem continues, reinstall GnuWin32 so that the files are extracted again.
Practice the Verification Sequence
A complete verification trace
A learner has installed GnuWin32 and wants to make zip available from a new command prompt.
- 1Locate the executable
Use File Explorer to check C:\Program Files\GnuWin32\bin and confirm that
zip.exeis present. - 2Configure PATH
Add C:\Program Files\GnuWin32\bin to the system PATH through the Environment Variables dialog.
- 3Refresh the command prompt
Close the existing command prompt and open a new one so the PATH change takes effect.
- 4Run the check
Type zip --version in the new command prompt.
- 5Interpret the result
Version information indicates that zip is recognized. A not-recognized error means that the installation, PATH entry, command prompt refresh, or terminal configuration needs further checking.
The verification is successful when a new command prompt displays the zip version number and other information after running zip --version.
After installing GnuWin32, zip --version still reports that zip is not recognized. Write the troubleshooting order you would follow before reinstalling GnuWin32.
Hints
- Check whether
zip.exeexists in the GnuWin32 bin directory. - Check the exact PATH entry for typos.
- Confirm that you opened a new command prompt.
- Consider whether your terminal application has a separate PATH configuration.
Key Takeaways
- 1Windows does not include the zip command by default, so install it from the GnuWin32 project page.
- 2The installed executable should be checked in C:\Program Files\GnuWin32\bin.
- 3Add C:\Program Files\GnuWin32\bin to the system PATH through the Environment Variables dialog.
- 4Close and reopen the command prompt after changing PATH.
- 5Run zip --version and look for version information to verify that the command is recognized.
The broader lesson is that operating systems locate command-line tools through configured paths. This same PATH concept is useful when working with Python, Node.js, Git, and other developer tools.
At a glance
- Install the zip command from the GnuWin32 project because Windows does not include it by default.
- Use the Environment Variables dialog to add C:\Program Files\GnuWin32\bin to the system PATH.
- Open a new command prompt after changing PATH.
- Run zip --version and confirm that version information appears.
- If the command is not recognized, check the executable, PATH spelling, command prompt age, and terminal configuration.