Allow Direct Database Access on GoDaddy Shared Hosting Plans

We have recently setup CodeGuard for one of our clients, and we’re in the process of setting up numerous sites on the CodeGuard platform. Getting the files adding for backup was as easy as providing FTP credentials. Backing up the database, however, proved to be a bit more difficult.

If you’re having trouble setting up database backups for CodeGuard on a GoDaddy shared hosting plan, it’s likely due to the following configuration option.

NOTE: This is not only true for CodeGuard backups. This is true for any third-party service that you want to access your database. It could be a backup solution, security analysis, integration with another website, etc.

However, we do not recommend using GoDaddy for hosting. If you’re looking for a great WordPress managed hosting provider, who will take care of all the backups for you, check out WP Engine.

Allow Direct Database Access on GoDaddy Shared Hosting

When creating a new database on a GoDaddy shared hosting plan (instructions here), there is an option to “Allow Direct Database Access.” It’s buried under an “Additional Options” toggle, and it’s set to NO by default.

If you do not allow direct database access, CodeGuard will not be able to backup your database.

And after talking to GoDaddy customer support, they confirmed that you cannot change this option once you’ve setup your database. It has to be configured when you first create the database.

A Solution To Fix This Problem

The following solution uses GoDaddy’s internal tools for backing up & restoring databases. You could alternatively access the old database via phpMyAdmin, export the database, create a new one, allow direct database access, and then import the .sql file you exported. If you’re comfortable with phpMyAdmin, that’s a perfectly viable solution.

Login to your GoDaddy Hosting Control Panel.

Scroll to the bottom & look for “Databases.” Click the “MySQL” icon.

Next to the database you need to allow direct access for, click the “Actions” button, and choose “Back Up.”

Allow Direct Database Access GoDaddy Shared Hosting
Click “Actions” & choose “Back Up”

Once your database backup is complete, click the “Add” button to add a new database. Give your new database a new name, but this time, make sure you select YES for “Allow Direct Access.”

Allow Direct Database Access - GoDaddy - Setup New Database
Create new database

Once the new database is setup, click the “Actions” button next to it, and choose “Restore.” You should have an option to restore the database that you just backed up. Select it.

After The Database Is Created

If you’re using a CMS, you’ll want to make sure you update your database credentials with the new database name, username & password. With GoDaddy, typically, the database name & username are the same thing.

If you’re using WordPress, open your wp-config.php file, and edit the database settings. You want to make sure your new database has been setup properly, and the restore is complete, before you do this.


Even GoDaddy themselves state that allowing direct database access is less secure. In no way am I suggesting you allow this option. I’m simply providing a solution to what I think might be a common problem. Enabling this option is entirely at your discretion.

By no means am I promoting GoDaddy’s hosting, either. GoDaddy’s shared hosting is not the best solution out there. It’s comparatively slow, and less secure, than other, more robust options.

If you’re looking for a great WordPress managed hosting provider, who will take care of all the backups for you, check out WP Engine.

Dave Warfel

Dave is the co-founder of Escape Creative, a web company focused on teaching WordPress. He creates new content over at WP Smackdown.

3 thoughts to “Allow Direct Database Access on GoDaddy Shared Hosting Plans”

  1. I bought godaddy hosting deluxe share hosting service.
    To get the mysql username / password etc. – godaddy says to click on details button next to database name. But there is no such button to click.
    all these have taken place after their changing the interface.

Leave a Reply

Your email address will not be published. Required fields are marked *