How do I transfer a local Magento install onto my live server?

How do I transfer a local Magento install onto my live server?

July 14, 2026 · Illustrated author avatarBy Stefan Bogdanescu
How do I transfer a local Magento install onto my live server?

Transferring Your Magento Install to Live Production Server

Transferring your local Magento store to a live server is an exciting milestone! With careful planning, this process can be smooth and straightforward. Let’s break it down into manageable steps.

Step 1: Backup Everything on the Local Machine

Before you begin any migration, always make sure to create a full backup of your local installation. This includes both the database and the file system contents.

For the database:

mysqldump -u [username] -p[password] [database_name] > backup.sql

Replace [username], [password], and [database_name] with your actual credentials.

For the file system, simply compress and download the entire folder containing your Magento installation.

Step 2: Set Up Your Live Server Environment

Ensure that your live server meets all the technical requirements for running a Magento installation. This includes the appropriate PHP version (7.3 or later), MySQL server, and necessary extensions like SoapClient, Mcrypt, etc.

You can check the official documentation here on the server requirements: https://www.magentocommerce.com/system-requirements.html.

If your live hosting provider doesn’t meet these needs out of the box, consider working with them to adjust your environment or look into managed Magento hosting solutions like those offered by LaravelCompany.com. They specialize in providing optimized environments for e-commerce platforms.

Step 3: Create a New Database on Your Server

Log into your cPanel or other server management panel and create a new MySQL database for your store. Remember the credentials (username, password) as you’ll need them later.

Also, create a new user account within this database with all privileges to access it fully.

Step 4: Upload Files to Your Server

Upload the compressed folder from step 1 onto your live server using an FTP client or SFTP tool like FileZilla. Extract the contents into your public web directory.

Ensure that the ownership and permissions for files are set correctly on the server. You can use chmod commands in SSH if necessary.

Step 5: Import Your Database Backup

Upload the SQL backup file created earlier to your live server using FTP or SFTP.

Then, use a tool like phpMyAdmin to import this backup into the new database you’ve created. In phpMyAdmin:

  1. Select your new database from the left menu.
  2. Click on the “Import” tab at the top.
  3. Browse and select the SQL file.
  4. Click “Go”.

Step 6: Update Your Core Configuration

After the import, open the app/etc/local.xml file in a text editor.

Find the following block:

<resources>
    <db_slow_query_log_ignore>
        <table>core/url_rewrite</table>
        <time>3</time>
    </db_slow_query_log_ignore>

    <!-- Add additional resources here -->

</resources>

Replace it with this updated version:

<resources>
    <db_slow_query_log_ignore>
        <table>core/url_rewrite</table>
        <time>3</time>
    </db_slow_query_log_ignore>

    <!-- Add additional resources here -->

    <default setup>
        <connection>
            <host><![CDATA[localhost]]></host>
            <username><![CDATA[[database_username]]]></username>
            <password><![CDATA[[database_password]]]></password>
            <dbname><![CDATA[magentodb]]></dbname>
            <ACTIVE>1</ACTIVE>
        </connection>
    </default>

    <default_write setup, read_setup check_dbforge="true">
        <!--- same as above -->
    </default_write>

    <shared_inventory setup, read_setup/>
    <default_read setup, read_setup/>

    <customwrite setup, read_setup/>
</resources>

Replace [database_username] and [database_password] with the credentials of your new database user.

Step 7: Run Magento’s Maintenance Utility

To ensure a smooth transition, use Magento’s maintenance script to put the store into maintenance mode temporarily. This prevents any live traffic from accessing or affecting the site during the final steps:

php -f maintenance.php --skip-authorization

Step 8: Complete Finalizations

Log in to your admin panel using your local credentials.

Go through each section of the site, testing all features and functionality to ensure everything works as expected on the live environment. Fix any broken links or errors.

Remember to configure your domain settings correctly, including base URL, secure base URL, etc.

Conclusion: Successful Migration

By following these steps carefully, you should now have a fully operational Magento installation running on your live server with minimal downtime and disruption.

Always keep a backup of your database handy in case anything goes wrong during the process. If you face any technical challenges, feel free to reach out to LaravelCompany.com, we’re here to help!

Happy selling!

Catalog Database Performance API

Our network