Skip to content

Knowledge Base

Importing a database

Load an SQL file into your database.


  1. Back up the destination first.
  2. Connect with a client, see Connecting to your database.
  3. Import the .sql file. In HeidiSQL use File › Run SQL file. In DBeaver use Tools › Execute script. Or from the command line:
mysql -h HOST -P PORT -u USER -p DBNAME < backup.sql

Tips

  • Large imports can time out in a web tool. Use a desktop client or the command line.
  • Create the database first. The import fills it.
  • Match the character set of the original.
Please rate this article to help us improve our Knowledge Base.

0 0