How to Install Xampp in Linux
Last Updated :
30 Sep, 2024
XAMPP is a popular and free open-source platform primarily used for PHP development. It comes bundled with essential tools like Apache Web Server, MySQL (MariaDB), PHP, Perl, and more, making it a one-stop solution for web development. Installing and setting up XAMPP is streamlined, and the package is available for all major operating systems, including Windows, Linux, and macOS.
In this article, we will discuss the step-by-step procedure to install Xampp in Linux-based Operating Systems.
Note: In Linux, xampp is named as lampp denoting "linux" in the starting character so it will be used interchangeably down the article.
Steps to Install XAMPP on Linux
Step 1: Download the XAMPP Installer for Linux
Open a new browser window and go to the Official Apache downloads webpage.
- Move to the Linux download links sections and download the latest installer package.
- Xampp uses ".run" shell script files to make it easy to automatically install the package without much manual intervention.
- It also supports every major distribution like Debian, Arch, Redhat, Ubuntu, and Manjaro.
download installer for linuxStep 2: Make the installer executable
- Once the installed is downloaded, we need to run the installer, by default no file will be given the executable permission.
- Open a new Terminal and go to the location of the installer file, most likely it is Downloads.
- Use the chmod command with x flag to give the executable permission for the installer using the below command.
sudo chmod +x xampp-linux-x64-8.2.12-0-installer.run
Here, +x adds executable permission to the file for everyone. If you prefer restricting the permission to the current user, replace +x with u+x.
make the installed executableStep 3: Run the Installer
- After providing the executable permission, run the installer to install the software in the system.
- Run the installer from the same terminal with Sudo permission using the below command.
- Sudo permission is required as by xampp uses the "/opt" directory to write down the files.
sudo ./xampp-linux-x64-8.2.12-0-installer.run
- A new Graphical window will be popped front, we can continue the installation process from there.
- In the below image we can see that it is requesting for further process, to proceed with the installation click on the Forward button in the bottom of the window.

- Here we need to select the components needs to be installed along with Xampp. There are different components like,
- Core files
- Developer files
- If its your development machine check the developer files also, I am going with the default options that is checked both the files.
- Click on the Forward button to proceed with the installation.

- Xampp alerting us it will install the modules and files under the "/opt/lampp" directory. It is the intended folder for software that is not part of the core linux system.
- We can't change the installation folder, so click on Forward button to accept the installation directory for Xampp.

- Now we have configured the installation and we can write the changes, so it prompts us for final question whether it can install Xampp on the System for the configuration.
- Click on Forward to accept the changes, in case you need to change anything cancel it and start from the beginning.
Now the installer is writing the files of the Software to our system. It may take a couple of minutes based on your Hardware configuration, sit back and relax until the installation is complete.

Feel free to uncheck the Launch Xampp checkbox, we will see how we can start Xampp in the next step. Finally Click on Finish to complete the Setup process.

Step 5: Start Xampp Program
- To start Xampp, either use the command line tool or the GUI manager.
- First of all move into the xampp installation folder using cd command.
cd /opt/lampp
Use the below command to start Xampp. This will start entire Xampp program including Apache, MysqlDB and others.
sudo ./lampp start
starting lampp with terminal- To just start the required services refer to the help page of Xampp. It includes options like
- startapache -> starts only apache server
- startmysql -> starts mysql
./lampp help

Using GUI Xampp Manager
To start the GUI Xampp manager, run the following command.
sudo ./manager-linux-x64.run
running gui managerChecking Xampp Server
- Once Xampp is started, open your browser and go to the `http://localhost/` url.
- A welcome page of Apache server will be displayed.
final output after installationUninstalling Xampp in Linux
- To Uninstall Xampp, open a new terminal window and move into the installation folder, here the "/opt/lampp" folder.
- Xampp tool ships with beginner friendly uninstaller executable, so that you don't have to mess with manual deletion of files and folders.
- Run the uninstall executable with sudo privilege to initiate the uninstallation process.
- Use the below command to uninstall the program, make sure you are in the intended directory.
sudo ./uninstall
Provide your super user password to start the process, double check you have backed up important data before proceeding with the uninstallation.
running uninstall xamppClick on "Yes" in the Question dialog box to proceed wit uninstallation. This will remove entire modules of the Xampp like Apache Server, Maria DB, etc. So, think before you act.
uninstalling xamppIn the above image, you can refer that its being uninstalled. Once the progress is over, you can close the terminal window.
Conclusion
In this article we have seen step by step procedure of installing Xampp, a easy to install suite of software that comes as a single package for Apache server, Maria DB, PHP. We have also seen how to uninstall it incase we need to completely remove the software from the System.
Similar Reads
How to install Virtualmin in Linux
In this article, we will learn to install Virtualmin on Linux Operating System. Virtualmin is based on Webmin, a popular web server management user interface for Linux. It is a domain hosting and website control panel that enables the creation and management of multiple domains and simplifies automa
3 min read
How to Install Vivaldi in Linux?
Vivaldi is a Customizable web browser that lets you customize everything in that browser. It is a good customizable, freeware, cross-platform web browser that was developed by Vivaldi technologies. It is based basically on Chromium. This browser was initially targeted towards technically-inclined us
3 min read
How to Install JDK in Linux?
Java is a very popular general-purpose programming language, which is very close to flow Oop's theory and can run independently on any platform, but its run time environment is dependent on the platform the JVM (Java Virtual Machine) is also known as. Which first interprets Java file byte code and b
2 min read
How to Install PHP GD in Xampp?
XAMPP is a free, easy-to-install Apache distribution containing MariaDB, PHP, and Perl. It allows you to build WordPress sites offline, on a local web server on your computer. It was first released in 2002. It is owned by Apache Friends and The PHP GD Graphics Library is a graphics software library
1 min read
How to install Sentora in Linux
Sentora is an Open-Source Web Hosting Control Panel that is used to build specifically to work on a variety of Linux. it's a free-to-download and use web hosting control panel developed for Linux, UNIX (it stands for UNICS 'UNiplexed Information Computing System' ), and BSD Based servers or computer
3 min read
How to Install PHP on Linux?
PHP is a popular server-side scripting language that is especially used in web development. If you're working on a Linux environment, whether it's a personal development setup or a production server, you will likely need PHP installed. In this article, we will see the step-by-step guide to install P
2 min read
How to Install Zip and Unzip in Linux?
Zip is a command-line compression utility for files and directories. File and folder compression allows for quicker and more reliable file and folder transfer, storage, and email. Unzip, on the other hand, is a program that allows you to decompress files and directories. zip is used to compress the
2 min read
How to Install SQLmap in Linux?
SQL Injection Vulnerability can be detected and exploited through various automated tools. It is an open-source cyber security tool that introduces its most powerful SQLi detection engine. All the task of flaw detection and gaining access to the database is done in an automated way. This tool is so
3 min read
How to install TinyCP in Linux
TinyCP is a lightweight control panel that can be accessed using web-UI and it is a nice alternative tool like cPanel for Linux servers to manage various services setting up in Linux is quite easy. You can easily create domains, databases, email, and FTP accounts, among other things, with the help o
4 min read
How to install Kloxo-MR in Linux
Kloxo-MR is a free web hosting panel available for Linux distributions. The name of the Lxadmin earlier knew it. But in 2017, The Lxadmin name was changed to the name Kloxo-MR. As there was some issue with the name. And also, there was a massive response from the user to change the application's nam
7 min read