Supported Versions
Check the
supported versions page for
more information on the support lifetime of each version of PHP.
Source Tarballs
Documentation Download
PHP Logos
Release Candidates
Development Sources (git)
Old Archives
';
site_header("Downloads",
[
'link' => [
[
"rel" => "alternate",
"type" => "application/atom+xml",
"href" => $MYSITE . "releases/feed.php",
"title" => "PHP Release feed",
],
],
"current" => "downloads",
"css" => [
"prism.css",
"code-syntax.css",
],
"js_files" => [
"js/ext/prism.js",
],
],
);
function option(string $value, string $desc, $attributes = []): string
{
return '' . $desc . ' ';
}
$usage = [
'web' => 'Web Development',
'cli' => 'CLI/Library Development',
'fw-drupal' => 'Drupal Development',
'fw-joomla' => 'Joomla Development',
'fw-laravel' => 'Laravel Development',
'fw-symfony' => 'Symfony Development',
'fw-wordpress' => 'WordPress Development',
];
$os = [
'linux' => [
'name' => 'Linux',
'variants' => [
'linux-debian' => 'Debian',
'linux-fedora' => 'Fedora',
'linux-redhat' => 'RedHat',
'linux-ubuntu' => 'Ubuntu',
'linux-docker' => 'Docker',
],
],
'osx' => [
'name' => 'macOS',
'variants' => [
'osx-homebrew' => 'Homebrew',
'osx-homebrew-php' => 'Homebrew-PHP',
'osx-docker' => 'Docker',
'osx-macports' => 'MacPorts',
],
],
'windows' => [
'name' => 'Windows',
'variants' => [
'windows-downloads' => 'ZIP Downloads',
'windows-native' => 'Single Line Installer',
'windows-chocolatey' => 'Chocolatey',
'windows-scoop' => 'Scoop',
'windows-docker' => 'Docker',
'windows-wsl-debian' => 'WSL/Debian',
'windows-wsl-ubuntu' => 'WSL/Ubuntu',
],
],
];
$versions = [
'8.4' => 'version 8.4',
'8.3' => 'version 8.3',
'8.2' => 'version 8.2',
'8.1' => 'version 8.1',
'default' => 'OS default version',
];
$platform = $_SERVER['HTTP_SEC_CH_UA_PLATFORM'] ?? '';
$ua = $_SERVER['HTTP_USER_AGENT'] ?? '';
$auto_os = null;
$auto_osvariant = null;
if (!empty($platform) || !empty($ua)) {
$platform = strtolower(trim($platform, '"'));
if ($platform === 'windows' || stripos($ua, 'Windows') !== false) {
$auto_os = 'windows';
} elseif ($platform === 'macos' || stripos($ua, 'Mac') !== false) {
$auto_os = 'osx';
} elseif ($platform === 'linux' || stripos($ua, 'Linux') !== false) {
$auto_os = 'linux';
if (stripos($ua, 'Ubuntu') !== false) {
$auto_osvariant = 'linux-ubuntu';
} elseif (stripos($ua, 'Debian') !== false) {
$auto_osvariant = 'linux-debian';
} elseif (stripos($ua, 'Fedora') !== false) {
$auto_osvariant = 'linux-fedora';
} elseif (stripos($ua, 'Red Hat') !== false || stripos($ua, 'RedHat') !== false) {
$auto_osvariant = 'linux-redhat';
}
}
}
$defaults = [
'os' => $auto_os ?? 'linux',
'version' => 'default',
'usage' => 'web',
];
$options = array_merge($defaults, $_GET);
if ($auto_osvariant && (!array_key_exists('osvariant', $options) || !array_key_exists($options['osvariant'], $os[$options['os']]['variants']))) {
$options['osvariant'] = $auto_osvariant;
} elseif (!array_key_exists('osvariant', $options) || !array_key_exists($options['osvariant'], $os[$options['os']]['variants'])) {
$options['osvariant'] = array_key_first($os[$options['os']]['variants']);
}
?>
Downloads & Installation Instructions
Did you find a mistake? Didn't find what you were looking for?
Please submit an issue .
Instructions
Source Code
GPG Keys
The releases are tagged and signed in the PHP Git Repository .
The following official GnuPG keys of the current PHP Release Manager can be used
to verify the tags:
A full list of GPG keys used for current and older releases is also
available.
Binaries
Binaries are available for
Microsoft Windows . The PHP project does not currently release binary packages
for other platforms such as Linux or macOS, but they are packaged by distributions
and other providers. For more information, see:
$SIDEBAR_DATA]);