Operations 10 min read

How to Search, Install, Update, and Remove Windows PHP Binaries with Winget

This guide explains how to use the Windows package manager winget to discover, download, install, update, and uninstall portable PHP binaries on Windows, covering version checks, package IDs, search commands, detailed show output, download options, installation effects on PATH, and removal steps.

Open Source Tech Hub
Open Source Tech Hub
Open Source Tech Hub
How to Search, Install, Update, and Remove Windows PHP Binaries with Winget

Winget Overview

Winget is the command‑line client for the Windows Package Manager service, allowing discovery, installation, upgrade, removal, and configuration of applications on Windows 10, Windows 11, and Windows Server 2025.

Check Winget Version

winget -v
v1.9.25200

Windows PHP Binaries

PHP binaries for Windows are hosted at windows.php.net. Each package is listed under the PHP.PHP namespace and includes SHA‑256 checksums and separate download links for x64 and x86 builds. Arm64 builds are currently unavailable.

Package IDs follow the pattern PHP.PHP.<major>.<minor>. For example, PHP 8.4 is available as PHP.PHP.8.4 (or the alias php8.4 following the Debian/Ubuntu naming convention).

Search for PHP Packages

To list all available PHP packages, run: winget search PHP.PHP Typical output shows the package name, ID, latest version, and source, e.g.:

Name    ID               Version   Source
------------------------------------------
PHP 8.1 PHP.PHP.8.1.31   winget
PHP 8.2 PHP.PHP.8.2.27   winget
PHP 8.3 PHP.PHP.8.3.15   winget
PHP 8.4 PHP.PHP.8.4.2    winget

This mirrors the experience of apt search php or dnf search php on Linux.

Show Package Details

To view metadata for a specific version, use: winget show PHP.PHP.%VERSION% Example for PHP 8.4: winget show PHP.PHP.8.4 The output includes publisher, homepage, license, download URL, SHA‑256 hash, and required dependencies such as Microsoft.VCRedist.2015+.x64.

Download a PHP Package

Download without installing by running: winget download php8.4 --skip-dependencies -d . Key options: --skip-dependencies – omit the Visual C++ runtime download. -d . – save the ZIP file to the current directory.

The command verifies the SHA‑256 hash, then saves a file such as PHP_8.4_8.4.2_X64_portable_en-US.zip (≈32 MB).

Install a PHP Package

Installation registers the package, validates the installer, extracts the archive, and updates the system PATH so the php command is available from any shell. winget install PHP.PHP.8.4 After installation you can run php -v to confirm the version and see that an alias such as php84 is also created (tracked in microsoft/winget-cli#2884 ).

Multiple Versions

Multiple PHP versions can coexist; installing a new version overwrites the php executable path with the most recent one. Each version also receives a version‑specific alias (e.g., php84 for PHP 8.4).

Verify Installed Version

php -v
PHP 8.4.2 (cli) (built: Dec 17 2024 17:30:12) (ZTS Visual C++ 2022 x64)

Update a PHP Package

When a newer patch is available, run: winget update PHP.PHP.%VERSION% For example, to update PHP 8.4:

winget update PHP.PHP.8.4

Remove a PHP Package

Winget does not provide a direct uninstall command for these portable packages; removal is performed via the Windows Settings UI: Settings → Apps → Installed apps, locate the PHP entry, and click **Uninstall**.

Original Source

Signed-in readers can open the original source through BestHub's protected redirect.

Sign in to view source
Republication Notice

This article has been distilled and summarized from source material, then republished for learning and reference. If you believe it infringes your rights, please contactadmin@besthub.devand we will review it promptly.

CLIPHPWindowswinget
Open Source Tech Hub
Written by

Open Source Tech Hub

Sharing cutting-edge internet technologies and practical AI resources.

0 followers
Reader feedback

How this landed with the community

Sign in to like

Rate this article

Was this worth your time?

Sign in to rate
Discussion

0 Comments

Thoughtful readers leave field notes, pushback, and hard-won operational detail here.