How to Install WordPress: Step-by-Step Guide
Most hosts can install WordPress for you in a few clicks. If yours can't, or you want full control, the manual method takes a little longer. This tutorial covers both, plus the settings to change straight afterwards.
On this page
WordPress is free software that runs on your hosting account. Installing it means copying its files to your site, connecting it to a database and creating your first administrator account. Most hosts automate all of this; the manual route gives you the same result with a few more steps.
Before you start
- Your host meets WordPress's recommendations. WordPress.org recommends PHP 8.3 or greater, MySQL 8.0 or greater (or MariaDB 10.11 or greater) and HTTPS support. Most current hosting plans meet these; your host's documentation will confirm it.
- Your domain points at your hosting. If you bought the domain elsewhere, update its nameservers or DNS records first. Changes can take a while to take effect.
- HTTPS is active. Turn on your host's free SSL certificate first, so WordPress is installed at the
https://address from the start. - You know where it should live. Usually that's the root of your domain (
yourdomain.com), not a subfolder. - Email works on your hosting. WordPress sends password resets and notifications by email, and the official guide suggests checking this before you install.
Method 1: Use your host's installer
This is the quickest and least error-prone route, and it's how most people install WordPress.
- Log in to your hosting control panel and look for a WordPress or "auto installer" option. The name varies by host.
- Choose your domain and the
https://version. Leave the directory field empty to install at the root of your domain. - Enter your site title. You can change it later in Settings.
- Create the administrator account. Avoid "admin" or your domain name as the username, use a long, unique password from a password manager, and use an email address you check regularly.
- Run the installer and wait for the confirmation.
- Log in at
yourdomain.com/wp-admin.
Method 2: Install WordPress manually
Use this method if your host has no installer, or you want to see exactly what's being set up. These steps follow the official WordPress installation guide.
1. Download WordPress
Download the latest version from wordpress.org, the official source, and unzip it on your computer.
2. Create a database and a database user
In your hosting control panel, create a new database and a database user, then give that user full privileges on the database. Note the database name, username and password, and the database host name your host shows, which is usually localhost. Some hosts create a database for you, so check first.
3. Set up wp-config.php (optional)
WordPress can create its configuration file for you during installation. To do it yourself, rename wp-config-sample.php to wp-config.php and fill in these values:
DB_NAME: the database nameDB_USER: the database usernameDB_PASSWORD: the database user's passwordDB_HOST: the database host, usuallylocalhost
Also fill in the "Authentication unique keys and salts" section with long, random values. Leave DB_CHARSET and DB_COLLATE as they are unless your host tells you otherwise.
4. Upload the files
Upload the contents of the WordPress folder, not the folder itself, to your site's root directory using your host's file manager or SFTP. To install in a subfolder such as /blog/, upload the folder and rename it instead.
5. Run the installer
Visit yourdomain.com/wp-admin/install.php. If WordPress can't find wp-config.php, it will ask for your database details and create the file. Then enter:
- your site title
- an administrator username and password
- your email address
- whether to discourage search engines from indexing the site (tick this only while the site is unfinished, and remember to untick it at launch)
Click Install WordPress, then log in.

First settings after installing

- Settings, General: check the site title and tagline, and set your time zone and date format.
- Settings, Permalinks: choose "Post name" for clean, readable addresses. Do this before you publish, because changing it later changes your URLs.
- Settings, Reading: choose whether the home page shows your latest posts or a static page, and check the search engine visibility setting.
- Settings, Discussion: turn comments off if you don't plan to use them, to avoid spam.
- Clean up: delete the sample post, sample page and any themes and plugins you won't use.
- Turn on backups through your host or a backup plugin before you add real content.
- Check for updates under Dashboard, Updates, and apply any that are waiting.
Next, choose a theme and a few essential plugins. Our guide to WordPress tools for beginners covers what most new sites need.


Fixing common installation problems
| What you see | Likely cause | What to try |
|---|---|---|
| An error connecting to the database | Wrong database details, missing privileges or the database server isn't running | Re-check DB_NAME, DB_USER, DB_PASSWORD and DB_HOST, confirm the user has privileges on the database, and ask your host whether the database server is up |
| "Headers already sent" | Usually an error in wp-config.php | Make sure nothing comes before the opening <?php tag, and save the file without a byte order mark |
| A list of files instead of your site | The server isn't loading index.php by default | Ask your host, or add a DirectoryIndex rule to .htaccess |
Raw <?php ?> code in the page | PHP isn't running correctly | Check that your plan supports PHP and meets WordPress's requirements |
| A message about a missing MySQL extension | PHP can't load its MySQL module | Ask your host to enable it |
If none of these fit, your host's support team can usually see the server's error log, which shows the exact problem.
Next steps
- Protect your new site with our tutorial on how to secure a WordPress website.
- Keep it fast with how to improve website speed.
- Planning the rest of the site? See how to start a website.
Frequently asked questions
Should I use my host's installer or install WordPress manually?
Use the installer if your host has one. It does the same job with fewer chances for mistakes. The manual method is useful when there's no installer or you need a custom set-up.
Can I install WordPress in a subfolder?
Yes. Upload the WordPress folder to your root directory and rename it, for example to blog, then run the installer at yourdomain.com/blog/wp-admin/install.php.
How do I log in after installing?
Go to yourdomain.com/wp-admin (or /wp-login.php) and use the administrator username and password you created.
Is WordPress free?
The WordPress software from wordpress.org is free. You pay for your domain and hosting, and optionally for premium themes or plugins.
Sources
- WordPress Advanced Administration Handbook: How to install WordPress (manual installation steps, setup screen and common problems)
- WordPress.org: Requirements (recommended PHP, database and HTTPS support)
- WordPress Advanced Administration Handbook: Hardening WordPress (choosing an administrator username)
Checked .