Skip to content
HOSTIGAN
WordPress

How to install WordPress with cPanel (step by step)

Install WordPress in cPanel with a one-click installer or by hand: database, wp-config.php, the setup wizard and the settings to change before you go live.

Beginner 5 min read Updated November 24, 2026

WordPress runs a large share of the web, and getting it onto a cPanel hosting account takes about ten minutes. This guide walks you through both ways to do it — the one-click installer most hosts include in cPanel, and the manual method — and then through the settings that are worth changing before anyone visits the site. By the end you will have a working WordPress site on HTTPS, with a sensible structure that is easy to back up and move later.

Before you start

A few decisions made now save you trouble later.

  • The domain must point to your hosting. If the domain still points somewhere else, the installer may work but you won't be able to open the site. See how to point your domain to your hosting if you're not sure.
  • Get HTTPS working first. Most cPanel hosts issue a free certificate automatically once DNS is in place. Installing WordPress with https:// from day one avoids mixed-content warnings and a URL change later. Our guide on SSL certificates and HTTPS explains how to check.
  • Pick a current PHP version. In cPanel, look for Select PHP Version or MultiPHP Manager and choose a supported PHP 8.x release.
  • Decide where WordPress lives. For your main domain that is usually public_html. An addon domain has its own document root, which cPanel shows when you create it.

Tip: Make sure the target folder is empty. A leftover index.html from a placeholder page can take priority over WordPress's index.php and make it look as if the installation failed.

Method 1: the one-click installer

Many cPanel accounts include an application installer such as Softaculous or WP Toolkit. The names of the fields differ slightly, but the flow is the same.

  1. Open cPanel and find the WordPress icon in the installer section.
  2. Choose Install and select the protocol (https://) and the domain.
  3. Leave the directory field empty to install in the root, or type a folder name such as blog.
  4. Enter the site title and tagline. You can change both later.
  5. Create the admin account. Avoid admin as the username and use a long, unique password stored in a password manager.
  6. Pick the site language.
  7. Open the advanced options if you want to choose the database name or table prefix, or switch on automatic backups and updates.
  8. Click Install and wait for the confirmation with your login link.

The installer creates the database, the database user, the wp-config.php file and the admin account in one go. If it warns that files already exist in the folder, stop and check what they are before you let it overwrite anything.

Method 2: installing WordPress manually

The manual route takes a little longer, but you see every moving part — useful knowledge the first time something breaks.

Create the database

In cPanel, open MySQL Databases (or the Database Wizard):

  1. Create a database, for example example_wp. cPanel adds your account prefix automatically.
  2. Create a database user with a strong generated password.
  3. Add the user to the database and grant All Privileges.

Write down the three values — database name, username and password. Our guide to MySQL databases in cPanel covers this screen in more detail.

Upload the files

Download the latest release from wordpress.org. In cPanel's File Manager, open the target folder, upload the ZIP and extract it. The archive contains a wordpress folder; move its contents up one level so that wp-admin, wp-includes and index.php sit directly in public_html. If you prefer the terminal, cPanel's Terminal (when enabled) does the same in a few commands:

cd ~/public_html
wget https://wordpress.org/latest.tar.gz
tar -xzf latest.tar.gz --strip-components=1
rm latest.tar.gz

Configure wp-config.php

Rename wp-config-sample.php to wp-config.php and edit these lines:

define( 'DB_NAME', 'account_example_wp' );
define( 'DB_USER', 'account_wpuser' );
define( 'DB_PASSWORD', 'YOUR_DATABASE_PASSWORD' );
define( 'DB_HOST', 'localhost' );

$table_prefix = 'wp_';

Replace the block of put your unique phrase here keys with fresh values from the official generator at https://api.wordpress.org/secret-key/1.1/salt/. These keys sign login cookies, so never reuse them between sites.

Run the setup wizard

Open your domain in a browser. WordPress asks for the site title, admin username, password and email, then installs its tables. You can log in at https://example.com/wp-admin.

Warning: "Error establishing a database connection" almost always means a typo in wp-config.php. Check that you used the full prefixed database and user names, that the user was added to the database, and that DB_HOST is localhost.

Installer or manual: which should you choose?

One-click installerManual install
Time2–3 minutes10–15 minutes
Database setupAutomaticYou create it
Control over names and prefixLimited (advanced options)Full
What you learnLittleHow WordPress is put together
Best forMost new sitesLearning, custom setups

For most people the installer is the right call. The result is identical, and you can still edit everything afterwards.

Settings to change right after installation

A fresh WordPress install works, but a few defaults are worth adjusting before you publish.

  • Settings → General: Check the site title, set the correct time zone and make sure both URLs start with https://.
  • Settings → Permalinks: Choose Post name so addresses look like example.com/about-us/ instead of ?p=123. Do this before you publish, because changing it later breaks existing links.
  • Settings → Reading: If you ticked Discourage search engines while building, remember to untick it at launch. It's the most common reason a new site never appears in Google — see getting your site indexed.
  • Clean up: Delete the sample post, the sample page and any themes and plugins you won't use. Unused code still needs updates and still adds risk.
  • Updates: Keep WordPress, your theme and your plugins current. Turn on automatic updates for minor releases at the very least.
  • Backups: Set up a backup routine before you add real content. Our guide on backing up and restoring WordPress shows the options.

Once the basics are in place, making WordPress faster is the natural next step.

Common problems after installing

  • You see the old placeholder page. Delete index.html from the folder, or clear your browser cache.
  • Redirect loop or "too many redirects". The site URLs and the HTTPS setup disagree. Set both URLs in Settings → General to the same https:// address.
  • Theme or plugin uploads fail. The file is larger than the PHP upload limit. Raise upload_max_filesize and post_max_size in cPanel's PHP options.
  • White screen. A plugin or PHP version conflict. Rename the wp-content/plugins folder temporarily to find out whether a plugin is to blame.

In short

Point the domain, enable HTTPS, choose PHP 8, then install WordPress either with the one-click installer or by creating a database and editing wp-config.php yourself. Afterwards, set permalinks, time zone and search engine visibility, remove what you don't need and set up backups before you add content.

WordPress at Hostigan

Hostigan's WordPress hosting comes with a one-click install and automatic core updates, so you can skip most of the steps above and start building. If you'd rather manage things yourself in cPanel, our web hosting plans give you the full control panel.

Frequently asked questions

Install in the root (public_html for your main domain) if WordPress is the whole website. Use a subfolder only when the site really lives at an address like example.com/blog, because moving it later means changing URLs in the database.

Next in “From domain to finished website” · 8 of 8How to install an SSL certificate and enable HTTPS in cPanel