XAMPP is a widely used and easy-to-install Apache distribution containing MariaDB, PHP, and Perl. Developers use XAMPP to build and test their applications in a local environment. In this tutorial, we’ll explain how to auto start XAMPP in Windows 10 so you don’t have to start it manually every time you turn on your computer.
Step 1: Create a Batch File
First, we need to create a batch file that will start XAMPP automatically. To do this, open a new Notepad file, and add the following lines:
@echo off cd "C:\xampp" start xampp_start.exe exit
Please note that you should replace C:\xampp with the path to your XAMPP installation directory if it’s different.
Now, save the Notepad file with the extension .bat, for example, xampp_autostart.bat. Make sure to select “All Files” in the “Save as type” dropdown before saving.
Step 2: Add the Batch File to the Startup Folder
To make the batch file run automatically when Windows starts, we need to place it in the Startup folder. Follow these steps:
- Press Win + R to open the Run dialog.
- Type shell:startup and press Enter to open the Startup folder.
- Copy the xampp_autostart.bat file you created earlier and paste it into the Startup folder.
Now, when you restart your computer, the XAMPP server will start automatically.
In this tutorial, we showed you how to auto start XAMPP in Windows 10 by creating a batch file and placing it in the Startup folder. Now you don’t have to worry about manually starting XAMPP every time you boot up your computer. Happy coding!