Setup & site building · Guide
How to Create Subdomain in WordPress (Step by Step)

Short answer
WordPress does not create subdomains itself. Add the subdomain in your hosting panel, point its DNS record to your server and issue an SSL certificate. Then install a separate WordPress site on it or use a Multisite network set to sub-domains.
Key takeaways
- Subdomains are created in hosting and DNS, not WordPress.
- cPanel adds subdomains under Domains.
- External DNS needs an A or CNAME record for the subdomain.
- Issue SSL before installing WordPress on the subdomain.
- Multisite with subdomains needs wildcard DNS.
How do you create a subdomain in WordPress?
Create the subdomain in your hosting control panel, make sure its DNS record points to your server, add SSL, then install a separate WordPress site on it or use a Multisite network with subdomains.
WordPress itself does not create subdomains. A subdomain such as blog.example.com or shop.example.com is set up at the hosting and DNS level first.
Once the subdomain exists, you decide what runs on it. Most people install a fresh WordPress site there. Others use WordPress Multisite to run several sites from one installation.
Which setup should you choose?
Choose a separate WordPress install for independent sites with their own plugins and users, and Multisite when you want many similar sites managed from one dashboard with shared themes and plugins.
| Option | Best for | Shared plugins and themes | Complexity |
|---|---|---|---|
| Separate install on subdomain | Blog, shop, help center, staging | No | Low |
| Multisite with subdomains | Many related sites, one admin team | Yes | Medium to high |
| Subdirectory instead | Content that should share SEO strength | Same site | Lowest |
Ask whether you really need a subdomain. Content in a subfolder like example.com/blog/ lives inside your main site, which many site owners find simpler to manage.
Our guide on when to use WordPress Multisite helps you decide between the network and separate sites.
How do you create a subdomain in cPanel?
In cPanel, open Domains, click Create A New Domain, enter the full subdomain such as blog.example.com, choose its document root folder, and submit.
Steps in recent cPanel versions:
- Log in to cPanel.
- Open Domains in the Domains section.
- Click Create A New Domain.
- Enter the full subdomain, for example
blog.example.com. - Untick the option to share the document root if you want a separate folder.
- Confirm the folder, such as
public_html/blogorblog.example.com. - Click Submit.
Older cPanel versions have a separate Subdomains tool with the same fields. The cPanel Domains documentation explains both.
If your domain uses your host's nameservers, cPanel creates the DNS record automatically.
How do you create a subdomain on other hosts?
On other hosts, look for a Domains, Subdomains or Sites section in the dashboard, add the subdomain name, and let the host create its folder and DNS record.
Many managed WordPress hosts let you add a subdomain as a new site or as an extra domain on an existing site. Some create a fresh WordPress install for it in one step.
The exact menu names vary, so search your host's help center for add subdomain.
On some managed hosts, a subdomain counts as a separate site on your plan. Check how many sites your plan allows before you start, so you are not surprised by an upgrade prompt halfway through.
If your host offers a staging feature, it may already use a subdomain such as staging.example.com. You do not need to create that one yourself. Our guide on setting up a staging site explains how host staging tools work.
How do you set up DNS for the subdomain?
If your DNS is managed outside your host, such as at your registrar or Cloudflare, add an A record for the subdomain pointing to your server's IP address, or a CNAME record pointing to a hostname your host gives you.
A typical A record looks like this:
| Type | Name | Value |
|---|---|---|
| A | blog | 203.0.113.10 |
Replace the IP with your server's real address, which your host shows in its dashboard.
Use an A record when your host gives you an IP address. Use a CNAME record when your host gives you a hostname instead, which is common on managed and cloud platforms.
If you use Cloudflare, decide whether the record should be proxied. Proxied records hide your server IP and use Cloudflare's certificate at the edge, while DNS-only records connect visitors straight to your host.
Cloudflare's guide to creating DNS records walks through the process there. Our guide to WordPress DNS settings explains record types in plain English.
DNS changes can take a little time to spread. See how long DNS propagation takes for what to expect.
How do you add SSL to the subdomain?
Issue an SSL certificate for the subdomain through your host's free certificate tool, such as AutoSSL or Let's Encrypt, before installing WordPress so the site uses https from the start.
Most hosts issue certificates automatically once DNS resolves to their server. If not, find the SSL or TLS section and run it for the new subdomain.
Let's Encrypt provides the free certificates many hosts use. A wildcard certificate covers all subdomains, which helps with Multisite networks.
For step-by-step help, see how to install an SSL certificate on WordPress.
How do you install WordPress on the subdomain?
Use your host's one-click installer, such as Softaculous or the host's own WordPress tool, select the subdomain as the target, leave the directory field empty, and complete the setup form.
Steps with a typical installer:
- Open the WordPress installer in your hosting panel.
- Choose https:// and select
blog.example.comfrom the domain list. - Leave the directory field blank so WordPress installs at the subdomain root.
- Set the site title, admin username, password and email.
- Click Install.
To install manually, create a new database and user, upload WordPress files to the subdomain's folder, and run the setup in your browser. The WordPress installation guide covers each step.
The new site is fully separate. It has its own dashboard at blog.example.com/wp-admin/, its own users and its own plugins.
That separation is useful for safety. A plugin problem on the subdomain will not break your main site, and you can give a writer or client access to one site without touching the other.
Remember to secure and maintain the new site too. Install updates, add backups and use strong admin passwords, just as you would on your main domain.
How do you use subdomains with WordPress Multisite?
Enable Multisite in wp-config.php, choose sub-domains during network setup, add a wildcard DNS record and wildcard subdomain on your host, then create each site from Network Admin.
Outline:
- Back up your site.
- Add
define( 'WP_ALLOW_MULTISITE', true );towp-config.php. - Go to Tools > Network Setup and choose Sub-domains.
- Copy the code WordPress gives you into
wp-config.phpand.htaccess. - Add a wildcard DNS record such as
*.example.compointing to your server. - Add a wildcard subdomain in your hosting panel if required.
- Go to My Sites > Network Admin > Sites > Add New to create subsites.
The Create a Network documentation describes the full requirements. Our guide on how to enable Multisite covers the details.
You cannot easily switch an existing network from subdirectories to subdomains later, so choose carefully.
Can you map a subdomain on WordPress.com?
Yes, WordPress.com lets you connect a subdomain of a domain you own to a site on certain plans, by adding it under the domain settings and creating the DNS records it asks for.
The steps and plan requirements change over time. Check the WordPress.com support pages for current instructions before you buy.
Do subdomains help or hurt SEO?
Subdomains are not bad for SEO, but search engines may treat them more like separate sites, so content usually builds authority faster in a subfolder unless it truly needs separate hosting or software.
Subdomains make sense for separate apps, help centers, regional sites or stores on different platforms.
If you move content from a subdomain to a subfolder later, use 301 redirects to keep traffic and links.
Why isn't my subdomain working?
A subdomain usually fails because DNS has not updated, the record points to the wrong IP, the SSL certificate has not been issued, or WordPress settings still use the main domain.
Check these:
- Look up the subdomain in a DNS checker to confirm it resolves to your server.
- Make sure the document root folder contains the WordPress files.
- Re-run the SSL tool after DNS resolves.
- In the subdomain's dashboard, check Settings > General for the correct WordPress Address and Site Address.
- Clear any CDN cache.
If you see a privacy warning, see fixing ERR_SSL_PROTOCOL_ERROR for certificate problems.
Frequently asked questions
Can I create a subdomain from the WordPress dashboard?
No. The WordPress dashboard cannot create DNS records or hosting folders. You create the subdomain in your hosting panel or DNS provider first. After that, you can install WordPress on it or add it as a site in a Multisite network.
Is a subdomain a separate WordPress site?
It usually is. When you install WordPress on a subdomain, it has its own files, database tables, users, themes and plugins. The only exception is Multisite, where subdomain sites share one installation and the same pool of themes and plugins.
How long does a new subdomain take to work?
If your host manages DNS, a new subdomain often works within minutes. With an external DNS provider, it can take longer while records spread, though many changes show up within an hour. SSL certificates are usually issued after DNS resolves.
Does a subdomain cost extra?
Usually not. Subdomains are free to create on a domain you own, and most hosting plans allow several. Some plans limit the number of websites you can host, so check your plan before adding new WordPress installs on subdomains.
Should I use a subdomain or subfolder for my blog?
A subfolder is usually simpler and keeps the blog inside your main site. A subdomain fits better when the blog runs on separate software or hosting. If your main site is already WordPress, a subfolder or the built-in posts page is often easiest.
Sources
- Domains cPanel Docs
- Create a Network WordPress Developer Resources
- How to Install WordPress WordPress Developer Resources
- Create DNS Records Cloudflare Docs
- Let's Encrypt Let's Encrypt
Is your product missing, or something out of date?
Tell us what to add or correct. We read every note and reply when we need a source. A message does not buy a ranking.
Thanks — we review requests within 3 business days.
Related guides
About the editors
Researched from the primary sources listed above and checked against our editorial rules before publishing.


