Is there a way to automatically backup a website database, say once a month?

I have cpanel and WHM running on all my shared hosting packages. It has a backup option but it's manual.

Important info:

  1. Needs to be Mac software
  2. I'm on shared hosting
  3. My FTP client is Transmit
  4. It needs to be a free solution


We've got Dropbox so if there was some way to automatically grab the mysql databases say once a month that would be great. As all our other backups are there anyways. But in the first instance let's just try to get an automatic backup to my computer!

  • Are you open to hosted solutions that require a small annual fee (e.g. $20 a year), or does your solution absolutely have to be Mac-based and free?
    – Nick
    Commented Jul 7, 2011 at 14:23
  • @Nick Yep mac based and free. We've just eaten our budget with a new CRM!!
    – Rob
    Commented Jul 7, 2011 at 14:51

2 Answers 2


I'm presuming you want to back up somewhere locally, rather than push the data somewhere else on the internet.

The getsqlbackup command which comes with some versions of cPanel can backup your databases for you. You need to get wget and then write a local batch file/script like this:

wget http://username:[email protected]:2082/getsqlbackup/databasename.gz --output-document=backupdir/databasename.gz

For backing up the files use this command

wget http://username:[email protected]:2082/getbackup/sitename.tar.gz --output-document=backupdir/sitename.tar.gz
  • 1
    Thanks. Yep definitely backup locally. Ok I'll give wget a go (I'll probably be back for more help on that!!). I'm using the FTP client Transmit so just trying to find out if it can backup automatically.
    – Rob
    Commented Jul 6, 2011 at 10:25
  • 1
    I checked out the manual option and I found it uses a similar command to the databases and so can be automated too. Bear in mind that the file it creates is a "zipped tar" file so you'll need an unzip program that knows what to do with it. Commented Jul 6, 2011 at 14:14

cPanel has built in back up functionality. It is found under Backup > Configure Backup. It can be set to run monthly and includes database data.

  • From what I saw, it was manual... I don't think I was looking at the wrong thing.
    – Rob
    Commented Jul 6, 2011 at 12:18
  • It should be automatic. I know mine is and I don't have anything special. If you don't see an option for "Backup Interval" then your cPanel might not offer this. Probably because it is a shared hosting environment.
    – John Conde
    Commented Jul 6, 2011 at 13:10
  • Yep that's the reason, it is shared.
    – Rob
    Commented Jul 6, 2011 at 13:13

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.