Skip to content

Creating a Database (cPanel)

Shop Craft needs a MySQL database to store your products, orders, customers, and settings. This guide walks you through creating one in cPanel, which is the most common hosting control panel.

Create the Database Before Installing

You should create your database before running the Shop Craft installer. You will need the database name, username, and password during Step 3 of the installation.

Step-by-Step Guide

1. Log in to cPanel

Log in to your hosting account's cPanel dashboard. The URL is usually one of:

https://yourdomain.com/cpanel
https://yourdomain.com:2083

Or you can access it through your hosting provider's website.

2. Open MySQL Databases

In cPanel, find and click MySQL Databases. It is usually located in the Databases section of the cPanel homepage.

3. Create a New Database

  1. In the Create New Database section, enter a name for your database (e.g., shopcraft)
  2. Click Create Database

Database Name Prefix

Most shared hosting providers automatically add your cPanel username as a prefix to the database name. For example, if your cPanel username is john and you enter shopcraft, the full database name will be john_shopcraft. Take note of the full name — you will need it during installation.

4. Create a Database User

Scroll down to the MySQL Users section:

  1. Enter a username (e.g., shopcraft)
  2. Enter a strong password (or click the Password Generator button to create one)
  3. Click Create User

Save Your Password

Copy and save the password somewhere safe. You will need it during installation, and cPanel will not show it to you again.

5. Assign the User to the Database

Scroll down to the Add User To Database section:

  1. Select the user you just created from the dropdown
  2. Select the database you just created from the dropdown
  3. Click Add
  4. On the privileges page, check ALL PRIVILEGES
  5. Click Make Changes

6. Done — Note Your Credentials

You now have everything you need for the installer. Make a note of:

DetailExample
Database Hostlocalhost (this is almost always correct on shared hosting)
Database Port3306 (the default — you rarely need to change this)
Database Namejohn_shopcraft (including any prefix your host added)
Database Usernamejohn_shopcraft (including any prefix)
Database PasswordThe password you set in Step 4

Ready to Install

You are now ready to use these credentials in Step 3 of the installation wizard.

Troubleshooting

"Access denied" error in the installer

  • Make sure you assigned the user to the database (Step 5 above)
  • Verify that the user has ALL PRIVILEGES on the database
  • Double-check the username and password — they are case-sensitive

"Unknown database" error

  • Check that the database name matches exactly, including any prefix (e.g., john_shopcraft, not just shopcraft)

Cannot find MySQL Databases in cPanel

  • Try searching for "MySQL" in the cPanel search bar
  • Some hosts label it as MySQL Database Wizard instead
  • Contact your hosting provider if you cannot locate it

Shop Craft Documentation