How to Install CodeIgniter 4 in Xampp

Download CodeIgniter 4 app from the official website, and extract it to the htdocs directory, then do some configuration and run it on xampp localhost server.

Let’s start the step by step guide to install and run the codeIgniter 4 application in xampp server:

Step 1: Download Codeigniter 4

Visit to, and download latest codeIgniter applicaiton version 4.

Step 2: Extract Downloded Zip in Htdocs

Navigate to the xampp/htdocs directory, extract the downloaded CodeIgniter archive into it, and then rename the extracted folder to match your project name.

Step 3: Connect app to Database

Edit application/config/database.php file, and set up database in it:

‘hostname’ => ‘localhost’,

‘username’ => ‘root’,

‘password’ => ‘’,

‘database’ => ‘your_database_name’,

Step 4: Configure Base URL

Edit application/config/config.php file, and set the base_url to your local development environment:

$config[‘base_url’] = ‘http://localhost/your_project_name/';

Step 5: Run Application

Open your web browser and type to http://localhost/your_project_name/ for testing.

I hope this tutorial help to install CodeIgniter 4.