Knowledge Base
MilesWeb / OpenCart FAQ

How to Change OpenCart Installation Folder?

Approx. read time : 2 min

Let’s assume that you have installed the OpenCart at and you want to move it to

To move the OpenCart from one folder to other, you will have to edit the following two files.


In both these files, you will find following lines that should be modified:


define('HTTP_SERVER', '');

define('HTTP_IMAGE', '');

define('HTTP_ADMIN', '');


define('HTTPS_SERVER', '');

define('HTTPS_IMAGE', '');

// DIR

define('DIR_APPLICATION', '/home/username/public_html/newfolder/catalog/');

define('DIR_SYSTEM', '/home/username/public_html/newfolder/system/');

define('DIR_DATABASE', '/home/username/public_html/newfolder/system/database/');

define('DIR_LANGUAGE', '/home/username/public_html/newfolder/catalog/language/');

define('DIR_TEMPLATE', '/home/username/public_html/newfolder/catalog/view/theme/');

define('DIR_CONFIG', '/home/username/public_html/newfolder/system/config/');

define('DIR_IMAGE', '/home/username/public_html/newfolder/image/');

define('DIR_CACHE', '/home/username/public_html/newfolder/system/cache/');

define('DIR_DOWNLOAD', '/home/username/public_html/newfolder/download/');

define('DIR_LOGS', '/home/username/public_html/newfolder/system/logs/');

In the above lines replace with your domain name, username with cPanel username and new folder with the directory name where your OpenCart is installed.

If you are not able to change the folder, contact us our team will fix it for you.

If you are looking for a quality OpenCart hosting provider, visit

With over 10+ years of experience in the web hosting industry, I have achieved extensive exposure to result-oriented methodologies. And expertise in different domains like Datacentre Services, Cloud computing technology, Web hosting industry and many more.