{"id":847,"date":"2026-10-16T03:00:00","date_gmt":"2026-10-16T03:00:00","guid":{"rendered":"https:\/\/vpslake.com\/blog\/?p=847"},"modified":"2026-10-16T03:00:00","modified_gmt":"2026-10-16T03:00:00","slug":"install-xampp-windows-server-2022","status":"publish","type":"post","link":"https:\/\/vpslake.com\/blog\/2026\/10\/16\/install-xampp-windows-server-2022\/","title":{"rendered":"How to Install XAMPP on Windows Server 2022"},"content":{"rendered":"\n<p class=\"wp-block-paragraph\">To install XAMPP on Windows Server 2022, use the official Windows installer, start Apache and MariaDB from the control panel, and test a PHP page. You can finish the basic setup in about ten minutes, then decide whether the site should remain private or be exposed through a firewall and domain.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Prerequisites<\/h2>\n\n\n\n<ul class=\"wp-block-list\">\n\n<li>A patched, 64-bit Windows Server 2022 installation with at least 2 GB of free disk space for XAMPP and your test files.<\/li>\n\n\n<li>An RDP session with a local administrator account that can approve UAC prompts and run elevated PowerShell.<\/li>\n\n\n<li>Outbound HTTPS access to download the installer from the <a href=\"https:\/\/www.apachefriends.org\/index.html\" target=\"_blank\" rel=\"noopener\">official Apache Friends XAMPP page<\/a>.<\/li>\n\n\n<li>A domain is not required for a local test. For a public website, prepare <code>YOUR_DOMAIN<\/code> and a TLS certificate before sending real traffic to the server.<\/li>\n\n\n<li>A <a href=\"https:\/\/vpslake.com\/buy-windows-rdp\">VPSLake Windows RDP server<\/a> if you need a Windows environment with administrator access.<\/li>\n\n<\/ul>\n\n\n\n<h2 class=\"wp-block-heading\">Step 1: Confirm Windows Server 2022 and the architecture<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Checking the OS first prevents you from troubleshooting an installer on an unsupported or incorrectly provisioned machine.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Open <strong>Start \u2192 Windows PowerShell<\/strong>, then run:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>Get-CimInstance Win32_OperatingSystem | Select-Object Caption, Version, OSArchitecture<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">Expected output resembles:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>Caption                         Version        OSArchitecture\n-------                         -------        --------------\nMicrosoft Windows Server 2022  10.0.20348    64-bit<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">Continue only when the caption identifies Windows Server 2022 and the architecture is <code>64-bit<\/code>. The exact build number can differ after Windows updates.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Step 2: Download the current XAMPP installer<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Getting the installer from Apache Friends ensures that the package and its version information come from the project\u2019s official download page.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">In the RDP session, open the <a href=\"https:\/\/www.apachefriends.org\/index.html\" target=\"_blank\" rel=\"noopener\">Apache Friends download page<\/a>, find <strong>XAMPP for Windows<\/strong>, and select the current Windows installer. Save the executable in <code>C:\\Users\\Administrator\\Downloads<\/code> or another folder you control. Do not use an installer copied from an unknown software site.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">The current XAMPP page identifies the bundle as Apache, MariaDB, PHP, and Perl. Although the control panel uses a <strong>MySQL<\/strong> label for the database module, modern XAMPP releases ship MariaDB; their commands and client tools are compatible for the basic checks in this guide.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Step 3: Install XAMPP outside Program Files<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Installing into a short top-level folder avoids Windows\u2019 protected <code>Program Files<\/code> permissions when you edit web files or configuration files.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Open the downloaded installer, approve the administrator prompt, and complete the wizard as follows:<\/p>\n\n\n\n<ol class=\"wp-block-list\">\n\n<li>Keep <strong>Apache<\/strong>, <strong>PHP<\/strong>, <strong>MySQL<\/strong>, and <strong>phpMyAdmin<\/strong> selected. Leave FileZilla, Mercury, Tomcat, and other optional components unselected unless your application specifically needs them.<\/li>\n\n\n<li>Set the installation folder to <code>C:\\xampp<\/code>. Do not lower or disable User Account Control; accept the normal UAC prompt when an administrative operation requires it.<\/li>\n\n\n<li>Keep the language and remaining defaults, select <strong>Next<\/strong>, and wait for the files to finish copying.<\/li>\n\n\n<li>Leave <strong>Launch XAMPP Control Panel<\/strong> selected and choose <strong>Finish<\/strong>.<\/li>\n\n<\/ol>\n\n\n\n<p class=\"wp-block-paragraph\">The official <a href=\"https:\/\/www.apachefriends.org\/faq_windows.html\" target=\"_blank\" rel=\"noopener\">XAMPP Windows FAQ<\/a> documents the installer, the control panel, the <code>C:\\xampp\\htdocs<\/code> document root, and the bundled MariaDB terminology.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Step 4: Start Apache and MariaDB<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">The control panel starts the two services independently, so you can keep the database stopped when a particular project does not need it.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">If the panel is not open, right-click <strong>Start \u2192 XAMPP Control Panel<\/strong> and select <strong>Run as administrator<\/strong>. In the panel, select <strong>Start<\/strong> next to <strong>Apache<\/strong>, then select <strong>Start<\/strong> next to <strong>MySQL<\/strong>. The rows should turn green and show <strong>Running<\/strong>; the MySQL row starts the bundled MariaDB server.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">For a first test, do not select <strong>Svc<\/strong> to install either module as a Windows service. Manual starts make it clear which components are running. If you later need automatic startup, install only the services you understand and manage them from <strong>Server Manager \u2192 Tools \u2192 Services<\/strong>.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Step 5: Create a local PHP test page<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">A small page in the XAMPP document root proves that Apache can serve files and that its PHP handler is working.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Open an elevated PowerShell window and run:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>@'\n&lt;?php\necho \"XAMPP on Windows Server 2022 is working\";\n?&gt;\n'@ | Set-Content -Path C:\\xampp\\htdocs\\health.php -Encoding ascii\n(Invoke-WebRequest -UseBasicParsing http:\/\/127.0.0.1\/health.php).Content.Trim()<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">Expected output:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>XAMPP on Windows Server 2022 is working<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">Keep the page only while testing. After verification, remove it or replace it with your application\u2019s real entry point:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>Remove-Item C:\\xampp\\htdocs\\health.php<\/code><\/pre>\n\n\n\n<h2 class=\"wp-block-heading\">Step 6: Allow public HTTP only when needed<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Localhost does not require an inbound firewall exception. If this server must serve a public HTTP site, allow TCP port 80 in Windows Firewall and in any VPS provider firewall, while leaving database port 3306 closed.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">In <strong>Administrator PowerShell<\/strong>, run:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>New-NetFirewallRule -DisplayName \"XAMPP Apache HTTP (TCP 80)\" -Direction Inbound -Action Allow -Protocol TCP -LocalPort 80 -Profile Domain,Private,Public\nGet-NetFirewallRule -DisplayName \"XAMPP Apache HTTP (TCP 80)\" | Select-Object DisplayName, Enabled, Direction, Action<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">Expected rule output includes:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>DisplayName                 Enabled Direction Action\n-----------                 ------- -------- ------\nXAMPP Apache HTTP (TCP 80)  True    Inbound  Allow<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">Do not open TCP 3306, phpMyAdmin, FTP, or mail ports to the internet. Do not add an HTTPS rule until Apache has a valid certificate and TLS virtual host configured; a plain XAMPP install is not automatically an HTTPS deployment. If you use a domain, point its DNS <code>A<\/code> record to <code>SERVER_IP<\/code>, then browse to <code>http:\/\/YOUR_DOMAIN\/<\/code> after Apache is running.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Verify XAMPP on Windows Server 2022<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Run these checks from the server to verify the web server, PHP CLI, database client, and listening port:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>Get-NetTCPConnection -LocalPort 80 -State Listen | Select-Object LocalAddress, LocalPort, State\nC:\\xampp\\php\\php.exe -v\nC:\\xampp\\mysql\\bin\\mysql.exe --version\ncurl.exe -I http:\/\/127.0.0.1\/<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">Successful output is similar to:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>LocalAddress LocalPort State\n------------ --------- -----\n0.0.0.0    80        Listen\n\nPHP 8.2.x (cli) ...\nmysql  Ver 15.1 Distrib 10.4.x-MariaDB ...\nHTTP\/1.1 200 OK<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">From another computer, replace the loopback address with <code>SERVER_IP<\/code> and request <code>http:\/\/SERVER_IP\/<\/code>. You should see the XAMPP dashboard or your site. If the local request succeeds but the remote request fails, work through the firewall checks below.<\/p>\n\n\n\n<aside class=\"vl-element vl-cta-banner\" aria-label=\"Run XAMPP on Windows\">\n\t<div class=\"vl-cta-banner__content\">\n\t\t<p class=\"vl-cta-banner__eyebrow\">Windows hosting<\/p>\n\t\t<h3 class=\"vl-cta-banner__title\">Run XAMPP on Windows<\/h3>\n\t\t<p class=\"vl-cta-banner__text\">Get an administrator-ready Windows environment for PHP development and web hosting.<\/p>\n\t<\/div>\n\t<a class=\"vl-cta-banner__button\" href=\"\/buy-windows-rdp\" aria-label=\"View Windows RDP\">View Windows RDP<\/a>\n<\/aside>\n\n\n\n<h2 class=\"wp-block-heading\">Troubleshooting<\/h2>\n\n\n\n<h3 class=\"wp-block-heading\"><code>make_sock: could not bind to address 0.0.0.0:80<\/code><\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">Another program already owns port 80, commonly IIS\u2019s World Wide Web Publishing Service. Find the process with:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>Get-NetTCPConnection -LocalPort 80 -State Listen | ForEach-Object { Get-Process -Id $_.OwningProcess }<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">If it is IIS and you do not need IIS, stop it from <strong>Server Manager \u2192 Tools \u2192 Services \u2192 World Wide Web Publishing Service<\/strong>, or run <code>Stop-Service W3SVC<\/code> in an elevated shell. Otherwise change Apache\u2019s <code>Listen<\/code> and <code>ServerName<\/code> ports in <code>C:\\xampp\\apache\\conf\\httpd.conf<\/code>, then browse to the new port.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\"><code>http:\/\/127.0.0.1\/<\/code> works, but <code>http:\/\/SERVER_IP\/<\/code> times out<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">Apache is running locally, but Windows Firewall, the provider\u2019s network firewall, or a missing public IP route is blocking the request. Confirm the TCP 80 rule above, allow TCP 80 in the VPS control panel if it has a separate firewall, and test by IP before troubleshooting DNS. Do not disable the firewall to solve this.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Windows denies edits under the XAMPP folder<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">This usually means XAMPP was installed under <code>C:\\Program Files<\/code>, where standard users cannot freely modify application files. Reinstall it under <code>C:\\xampp<\/code> or edit from an elevated account; do not grant broad write access to the entire disk.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">MySQL will not start or port 3306 is already in use<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">An existing MySQL or MariaDB service may already be listening on the database port. Check with:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>Get-NetTCPConnection -LocalPort 3306 -State Listen -ErrorAction SilentlyContinue\nGet-Service | Where-Object { $_.Name -match 'mysql|maria' }<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">Stop the other database only if you know it is unused, or keep it and do not start XAMPP\u2019s database module. Never delete <code>C:\\xampp\\mysql\\data<\/code> as a first fix; that can destroy databases.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Hardening<\/h2>\n\n\n\n<ul class=\"wp-block-list\">\n\n<li>Treat XAMPP as a development bundle, not a production security baseline. The project\u2019s FAQ warns that the default configuration is intentionally open and may leave the database administrator without a password.<\/li>\n\n\n<li>Set a strong MariaDB root password from the local XAMPP security page at <code>http:\/\/127.0.0.1\/security\/<\/code>, and keep phpMyAdmin restricted to localhost. Never publish phpMyAdmin as a general internet endpoint.<\/li>\n\n\n<li>Leave FileZilla, Mercury, Tomcat, and port 3306 stopped unless your project needs them. Create a separate database user for each application instead of using <code>root<\/code> in application code.<\/li>\n\n\n<li>Keep Windows Server 2022 patched, back up <code>C:\\xampp\\htdocs<\/code> and database data, and configure TLS before collecting credentials or serving a public login page.<\/li>\n\n<\/ul>\n\n\n\n<h2 class=\"wp-block-heading\">FAQ<\/h2>\n\n\n\n<h3 class=\"wp-block-heading\">Is XAMPP the same as installing MySQL on Windows Server 2022?<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">No. XAMPP is a bundled development environment that includes Apache, PHP, Perl, and MariaDB, along with a control panel and optional tools. The panel may call the database row \u201cMySQL,\u201d but the bundled server is MariaDB in current XAMPP releases.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Can I use XAMPP for a production website?<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">The software can serve a site, but Apache Friends describes XAMPP as a development environment and warns that its defaults are too open for production. For a public service, harden every component, use TLS, restrict administration, separate database credentials, and consider deploying a production-focused stack instead.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Do I need a domain name to install XAMPP?<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">No. <code>http:\/\/127.0.0.1\/<\/code> tests the server locally, and <code>http:\/\/SERVER_IP\/<\/code> works for a basic remote test once the firewall allows port 80. A domain becomes useful when you need stable URLs, DNS, and a trusted TLS certificate.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Why does XAMPP use MariaDB instead of MySQL?<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">XAMPP has shipped MariaDB in place of MySQL for many years, while retaining compatible command-line tools and the familiar control-panel label. Applications that require a specific database engine or version should be checked against that requirement before deployment.<\/p>\n\n\n\n<script type=\"application\/ld+json\">{\"@context\": \"https:\/\/schema.org\", \"@type\": \"FAQPage\", \"mainEntity\": [{\"@type\": \"Question\", \"name\": \"Is XAMPP the same as installing MySQL on Windows Server 2022?\", \"acceptedAnswer\": {\"@type\": \"Answer\", \"text\": \"No. XAMPP is a bundled development environment that includes Apache, PHP, Perl, and MariaDB, along with a control panel and optional tools. The panel may call the database row \u201cMySQL,\u201d but the bundled server is MariaDB in current XAMPP releases.\"}}, {\"@type\": \"Question\", \"name\": \"Can I use XAMPP for a production website?\", \"acceptedAnswer\": {\"@type\": \"Answer\", \"text\": \"The software can serve a site, but Apache Friends describes XAMPP as a development environment and warns that its defaults are too open for production. For a public service, harden every component, use TLS, restrict administration, separate database credentials, and consider deploying a production-focused stack instead.\"}}, {\"@type\": \"Question\", \"name\": \"Do I need a domain name to install XAMPP?\", \"acceptedAnswer\": {\"@type\": \"Answer\", \"text\": \"No. `http:\/\/127.0.0.1\/` tests the server locally, and `http:\/\/SERVER_IP\/` works for a basic remote test once the firewall allows port 80. A domain becomes useful when you need stable URLs, DNS, and a trusted TLS certificate.\"}}, {\"@type\": \"Question\", \"name\": \"Why does XAMPP use MariaDB instead of MySQL?\", \"acceptedAnswer\": {\"@type\": \"Answer\", \"text\": \"XAMPP has shipped MariaDB in place of MySQL for many years, while retaining compatible command-line tools and the familiar control-panel label. Applications that require a specific database engine or version should be checked against that requirement before deployment.\"}}]}<\/script>\n\n","protected":false},"excerpt":{"rendered":"Install XAMPP on Windows Server 2022 with Apache, MariaDB, PHP, firewall rules, a working test page, security tips, and common fixes for new VPS admins.","protected":false},"author":1,"featured_media":848,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"csco_singular_sidebar":"","csco_page_header_type":"","csco_page_load_nextpost":"","footnotes":""},"categories":[5,11],"tags":[71,73,72,52,70],"class_list":["post-847","post","type-post","status-publish","format-standard","has-post-thumbnail","category-guides","category-windows-server","tag-apache","tag-mariadb","tag-php","tag-windows-server-2022","tag-xampp","cs-entry"],"_links":{"self":[{"href":"https:\/\/vpslake.com\/blog\/wp-json\/wp\/v2\/posts\/847","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/vpslake.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/vpslake.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/vpslake.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/vpslake.com\/blog\/wp-json\/wp\/v2\/comments?post=847"}],"version-history":[{"count":1,"href":"https:\/\/vpslake.com\/blog\/wp-json\/wp\/v2\/posts\/847\/revisions"}],"predecessor-version":[{"id":3415,"href":"https:\/\/vpslake.com\/blog\/wp-json\/wp\/v2\/posts\/847\/revisions\/3415"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/vpslake.com\/blog\/wp-json\/wp\/v2\/media\/848"}],"wp:attachment":[{"href":"https:\/\/vpslake.com\/blog\/wp-json\/wp\/v2\/media?parent=847"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/vpslake.com\/blog\/wp-json\/wp\/v2\/categories?post=847"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/vpslake.com\/blog\/wp-json\/wp\/v2\/tags?post=847"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}