In this tutorial, we will see how you can install and configure CodeIgniter. 

CodeIgniter framework is available on the official CodeIgniter website. If you want to download the framework, you have to do so from the official website. Download CodeIgniter now.

  • Clicking the above link and download the framework as a zipped folder.
  • Unzip it you will see the following files and folders

CodeIgniter Config Files

Step 1: go to application/config/config.php lets open it in your code editor and set the base URL

$config['base_url'] = '';

base_url:- is just only your website URL or your project name if your are working on XAMPP Local Server.

Database Connectivity

Step 2: go to application/config/database.php lets open it in your code editor and set the base URL

$db['default'] = array(
	'dsn'	=> '',
	'hostname' => 'localhost',
	'username' => 'root',
	'password' => '',
	'database' => 'tutorial',
	'dbdriver' => 'mysqli',
	'dbprefix' => '',
	'pconnect' => FALSE,
	'db_debug' => (ENVIRONMENT !== 'production'),
	'cache_on' => FALSE,
	'cachedir' => '',
	'char_set' => 'utf8',
	'dbcollat' => 'utf8_general_ci',
	'swap_pre' => '',
	'encrypt' => FALSE,
	'compress' => FALSE,
	'stricton' => FALSE,
	'failover' => array(),
	'save_queries' => TRUE

Set the database username, password and database name. here my database name is tutorial, username is root and password is blank i don't have password to set.

Now you have successfully installed CodeIgniter need to run open your browser and type http://localhost/your_project_name