Database syncing with Craft CMS
Published
Updated
Export and import your Craft CMS database between local development and fortrabbit using MySQL tools and techniques.
Install and deploy run down
- Install Craft CMS locally
- Setup an app at fortrabbit
- Deploy code via Git
- Database syncing ← you are here
- Assets syncing
Database connection
Craft CMS on fortrabbit connects to the MySQL database through the ENV vars of the software template. After the first deployment, the database is still empty: import the local database to bring content and structure up. The MySQL export and import guides cover the terminal and GUI ways.
Database up
- Export the local database
- Upload the dumped
.sqlfile - Import the database dump into the app environment database
Database down
Download the database once editors work on the live site, to develop locally with current content.
- Export the remote database
- Download the dumped
.sqlfile - Import the database in your local development