Table of Contents
In CodeIgniter 3, we have a constant variable to see CodeIgniter version i.e CI_VERSION. But in CodeIgniter 4, we have some different approach.
Note*: For this article, CodeIgniter v4.1 setup has been installed. May be when you are seeing, version will be updated. CodeIgniter 4.x still is in development mode.

Let’s see from Installation.
Download & Install CodeIgniter 4 Setup
We need to download & install CodeIgniter 4 application setup to system. To set application we have multiple options to proceed. Here are the following ways to download and install CodeIgniter 4 –
- Manual Download
- Composer Installation
- Clone Github repository of CodeIgniter 4
Complete introduction of CodeIgniter 4 basics – Click here to go. After going through this article you can easily download & install setup.
Here is the command to install via composer –
$ composer create-project codeigniter4/appstarter codeigniter-4
Assuming you have successfully installed application into your local system.
Find CodeIgniter Version ?
We have two options to see where we can find it. First either by going through the located file and second we can print the version by Constant.
Version Located File
Need to go installed setup and find this path & file – /vendor/codeigniter4/framework/system/CodeIgniter.php
Inside this CodeIgniter.php file, you should see we have a class named with CodeIgniter and a constant in that class as const CI_VERSION = ‘4.1.1’;
This 4.1.1 in my case, in your case it may be different due to new released versions.
Print CodeIgniter Version in application
Inside this we need to use same CodeIgniter class by the help of it’s namespace. Have a look, we have created a controller to print the value.
<?php namespace App\Controllers; class Home extends BaseController { public function showVersion() { echo \CodeIgniter\CodeIgniter::CI_VERSION; } }
We hope this article helped you to learn about to find CodeIgniter 4 application version in a very detailed way.
If you liked this article, then please subscribe to our YouTube Channel for PHP & it’s framework, WordPress, Node Js video tutorials. You can also find us on Twitter and Facebook.
Find More on CodeIgniter 4 here
- CodeIgniter 4 Cookie Helper Tutorial
- CodeIgniter 4 CRUD Application Tutorial
- CodeIgniter 4 CRUD REST APIs Tutorial
- CodeIgniter 4 CSRF Token in AJAX Request
- Database Query in CodeIgniter 4 Tutorial
- CodeIgniter 4 Ajax Form Data Submit
- CodeIgniter 4 Form Validation Tutorial
- CodeIgniter 4 Image Upload with Form Tutorial
- Multi language in CodeIgniter 4 Tutorial
- Stripe Payment Gateway Integration in CodeIgniter 4
- CodeIgniter 4 CSRF Token Tutorial
- CodeIgniter 4 Basics Tutorial
- CodeIgniter 4 Spark CLI Commands Tutorial
- Migration in CodeIgniter 4 Tutorial
- Seeders in CodeIgniter 4 Tutorial
Hi, I am Sanjay the founder of ONLINE WEB TUTOR. I welcome you all guys here to join us. Here you can find the web development blog articles. You can add more skills in web development courses here.
I am a Web Developer, Motivator, Author & Blogger. Total experience of 7+ years in web development. I also used to take online classes including tech seminars over web development courses. We also handle our premium clients and delivered up to 50+ projects.
Thank you for some other excellent article. The place else could anybody
get that type of information in such an ideal way of writing?
I have a presentation subsequent week, and I am at the look
for such information.