CodeIgniter with Apache2

Linode Staff

I would like to use the CodeIgniter PHP framework with an Apache2 web server on a Linode. How do I properly set this up on Ubuntu?

1 Reply

What Do You Need

I'm testing this configuration with Ubuntu 18.10 and CodeIgniter v3.1.9, but you'll need:

Downloading and Installing

  • Navigate to the Apache root folder

cd /var/www/html

  • Grab the download URL for CodeIgniter from CodeIgniter's website

  • Download CodeIgniter to your Linode via wget

sudo wget

  • Unzip the file

sudo unzip

Note: My configuration didn't include unzip, so if that's the case for you, run
sudo apt install unzip

  • Rename the newly unzipped folder

sudo mv CodeIgniter-3.1.9/ codeigniter

  • Remove the zip file and the default Apache index page

sudo rm && sudo rm index.html

Next Steps

At this point, you should be able to see CodeIgniter's default page by navigating to http://$IPAddress/codeigniter in your browser, using your Linode's public IPv4 address in the place of $IPAddress. From here, you'll want to secure your website's files by using an htaccess file, optimize MySQL, Apache, and PHP for your website, and set up your website's domain name.

More Information

The documentation for CodeIgniter is quite thorough and should be able to answer any questions that come up while you set up your website.


Please enter an answer

You can mention users to notify them: @username

You can use Markdown to format your question. For more examples see the Markdown Cheatsheet.

> I’m a blockquote.

I’m a blockquote.

[I'm a link] (

I'm a link

**I am bold** I am bold

*I am italicized* I am italicized

Community Code of Conduct