Migrating your PrestaShop store to a new server is one of the technical tasks any online store owner is confronted with at some point in time. It isn’t particularly difficult to move your entire e-commerce to a different server. That said, there are a number of factors to take into account and a procedure to follow in a set order to avoid problems with your website.
Here, we give you a guide to make the migration using PrestaShop version 1.7
Steps
- Put your store in maintenance mode: In dashboard go to:
– “shop parameters”
– “General”
– “Maintenance” page
– Change “Enable Shop ” to” No”
– Then click “save”.
Note: Maintenance mode allows you to hide your site from visitors while it’s under construction. You can add your IP to disable maintenance mode for your IP only. - Export current database and name it “oldStoreDB” (You will use it if something goes wrong):
– FindphpMyAdmin
in your server then
– Choose your database
– Click export - Change shop url to a new url :in dashboard go to:
– Shop parameters
– Traffic and SEO
– Shop url
– Set shop url - Export database again and name it “newStoreDB”.
- Back up all files in your old server and download it to your computer.
- Create database in new store server and import “newStoreDB”:
– FindphpMyAdmin
in a new server
– Choose your database
– Click import
– Choose “newStoreDB
” then click go. - Upload your store files (step 5) to a new server.
- Set your new server parameters:
– Go to filemanager > app > config > parameters.php
– Set new"Database_name"
,"database_password"
,"database_user"
,"database_host"
, and"databse_port"
For example:'database_host' => '127.0.0.1',
'database_port' => '3306',
'database_name' => ‘myStoreDb’',
'database_user' => 'root',
'database_password' => '12345' - Go to the file manager and rename the .htaccess file to ‘old_ahtaccess’ (if you don’t find it go to file manager settings and show hidden files).
- Clear cache:
– Go to dashboard
– “advanced parameters”
– “performance”
– “clear cache”
– OR You can clear cache manually by delete this folder content exceptindex.php
:
–cache/smarty/compile
- cache/smarty/cache
- img/tmp - Finally, generate new
.htaccess
file:
– Go to dashboard
– Traffic and SEO
– Disable friendly url
– Click save then enable friendly url again and click save
Notes:
- We recommend backup files and export databases when your new shop is ready and everything is working
- If you want to use an old store for testing or developing, you can export oldStoreDB (step 2) on your old store.
Really interesting information.
Thanks for it.