twerple logo
Loading experience...
twerple logo

Importing a database

1 min read • Updated 2 weeks ago • Databases

Load a .sql backup from your old host or your computer into a Twerple database.


When you move a website to Twerple, you usually bring its database with you as a .sql file, sometimes compressed as .sql.gz or .zip.

Importing with phpMyAdmin

  1. Create an empty database for it, if you have not already.
  2. Open the database in phpMyAdmin.
  3. Click the Import tab.
  4. Click Choose File and select your .sql, .sql.gz or .zip file.
  5. Leave the other settings as they are and click Import (or Go).
  6. When it finishes, the tables appear on the left.

If the file is too large

phpMyAdmin limits the size of files you can upload. If yours is over the limit:

  • Compress it first: a .sql.gz file is often ten times smaller.
  • If your plan includes SSH, upload the file with SFTP and import it from the command line:
    mysql -u example_shop -p example_shop < backup.sql
  • Or open a support ticket, tell us where you have uploaded the file and which database it is for, and we will import it for you.

Common errors

  • "Table already exists": the database is not empty. Import into a new, empty database, or delete the existing tables first.
  • "Access denied ... CREATE DATABASE": the file tries to create its own database. Remove the CREATE DATABASE and USE lines near the top of the file and import it again.
  • Odd characters after import: the file was exported with a different character set. Re-export it from your old host as utf8mb4.

After importing, update your website's configuration with the new connection details.

Was this article helpful?