Skip to content

Create databases and use phpMyAdmin

Most dynamic websites, including WordPress, store their content in a database. Sheernox hosting includes MariaDB, which works with software built for MySQL, and PostgreSQL for applications that support it. WordPress uses MariaDB. The phpMyAdmin steps below apply to MariaDB only.

Open Websites, select the website and select Databases in its navigation bar.

A website's Databases page with one database. Marker 1 is below the Add database button, marker 2 below Add user, marker 3 beside the phpMyAdmin button on the database's row and marker 4 above the database's menu button.
The Add database form. Marker 1 is beside the Database name field, which starts with a fixed prefix, marker 2 beside an existing database user that can be ticked, marker 3 beside Create new user and marker 4 above the Add button.
  1. Select Add database marker 1.

  2. Enter a name in Database name marker 1. Every name starts with a prefix based on the website, which you cannot change. The full name, prefix included, is the one your application needs.

  3. Give a user access to the database. If the website already has database users, they are listed under Add database user: tick one marker 2 to give it access. To make a new one, select Create new user marker 3:

    • Enter a Username (it gets the same prefix) and a Password. The password needs at least 10 characters, with a lowercase letter, an uppercase letter, a number and a special character. Save it in your password manager.
    • Leave All database privileges selected unless you need to limit what the user can do.
  4. Select Add marker 4.

To add a user later, select Add user on the Databases page, or open the database and use Add database user.

Your application needs four values: the database name, the username, the password and the database host. For WordPress and other PHP software on the same website, the host is localhost.

To see every connection option, select the database’s menu button marker 4, then Manage.

A database's Manage page. Marker 1 is beside the note that PHP applications can use localhost as the database host, marker 2 beside the PhpMyAdmin button and marker 3 beside the page's section list: Connection info, PhpMyAdmin, Users, Import SQL file and Export SQL file.

Connection info marker 1 shows the socket path for applications that connect through a Unix socket, and an address for applications that need a TCP connection.

phpMyAdmin is a browser tool for looking at and editing your data. It opens in a new tab, already signed in to the database.

  • On the Databases page, select the phpMyAdmin button marker 3 on the database’s row, or
  • on the database’s Manage page, select PhpMyAdmin marker 2.

The website’s overview also has phpMyAdmin in Quick links.

On the database’s Manage page:

  • Export SQL file: select Download to save the whole database as a .sql.gz file. Do this before major changes.
  • Import SQL file: select Upload and choose a .sql file, or one compressed as .gz or .zip. The page shows the largest file you can upload.

phpMyAdmin also has Export and Import tabs if you want to export only some tables.

Select the database’s menu button marker 4, then Delete, and confirm. The data is gone unless you have an export or a backup.

PostgreSQL is included on every Shared, Business, WordPress and Reseller Hosting plan. Its database allowance is separate from MariaDB and has the same limit. Shared Essential, Plus, Pro and Ultra include 10, 25, 75 and 150 databases of each type, respectively. WP Launch, Elevate and Scale include 5, 15 and 40 of each type, respectively. Business Core, Plus and Ultra include 100, 250 and 500 of each type, respectively. Reseller plans include unlimited databases of both types within their storage and resource allocation.

  1. Open Websites in the left sidebar and select your website.
  2. Select Databases in the top navigation, then Add database and enter the database name.
  3. Complete the Add database user form to create a new user, or select an existing database user. Save any new credentials securely. For PostgreSQL, All database privileges cannot be deselected.
  4. Select Add to finish.

When you create the website’s first PostgreSQL database, Enhance creates a PostgreSQL role matching the website’s system username. This role owns all PostgreSQL databases created under that website. Over website SSH, use psql to manage them with the owner credentials stored in .pgpass in the website’s home directory. Keep this file private.

Enhance turns on the PHP pgsql and pdo_pgsql extensions when you create a PostgreSQL database. Select the PostgreSQL driver in your application’s configuration. phpMyAdmin manages MariaDB, not PostgreSQL. If you need help connecting, contact support with the website and error message, without sending your password.

Enhance backups include PostgreSQL databases.