Even though they might seem similar, a subdomain and a subdirectory are far from being the same thing. They are both branches of your main domain; however, the way they are configured and set is completely different...
...Also, changing them can affect your SEO.
To make matters simpler, we will explain what each of them is and their differences. You will also see a general discussion on the use of subdomains and subdirectories. In the end, you will learn how to configure and install each one using different installations or WordPress Multisites, ok?
But, before that, let's see an overview of each:
What is the domain?
The domain is a name or digital address of a website on the internet — for instance, rockstage.io. It consists of the given name and the extension, which are chosen when you create and purchase your domain.
A created domain is exclusive and, in order to be used, it must be registered. You can do that through websites that are partnered to official organizations that control the extensions you wish to register. Domain with popular extensions such as .br, .com and others are paid. A common example is registro.br, responsible for the .com.br extension.
What is a subdomain?
A subdomain is a digital address that is part of a domain. That is, it is a ramification of a domain. With it, you can create as many subdomains as you want from a valid domain.
The subdomain contains the main domain and is differentiated by the addition of another name or expression besides the main one. For instance: help.rockstage.io.
In this case, we identify it is a subdomain since it includes the main domain—rockstage.io—with the word "help" before it.
What is a subdirectory?
A subdirectory is a folder or directory that is created from your main website. For instance: help.rockstage.io/articles.
It is possible to have various subdirectories, just as you would organize the folders on your computer. It can also have multiple levels, such as in rockstage.io/articles/domain.
The use of subdomains and its effect on SEO
There are two sides to the debate on the use of subdirectories and subdomains, and both have experts defending them.
For instance, on Rock's blog, a subdirectory was used to organize the website at rockcontent.com/blog. However, on the community site, we chose to go with the subdomain comunidade.rockcontent.com. Do not be alarmed, as you will find several other successful businesses that choose in favor of a subdomain or subdirectory depending on their content strategy.
With that in mind, experts stay in the middle and say that there is little to no effect with either approach. Others also say you must try to avoid using a subdomain, as it might negatively affect your SEO.
“Google Web Search has no issue with subdomains or subdirectories.”
In the video, he explains that using subdomains makes having your content indexed by Google take a little longer. But, in the end, there is no difference between the two, and you must choose a strategy and stick with it. You have to be mindful about keeping your choice in the long term, no matter which one you pick. And, if you decide to switch, you need to follow these steps to make sure you do not lose traffic or have SEO issues:
- Configure the appropriate redirections from the subdirectories to the subdomains or the other way around.
- Let Google Analytics know about your site's indexing once again.
So, after all, which is the best to use? Here are a few tips to help you decide once and for all!
Subdomains vs. Subdirectories: which is better for SEO?
Well, according to Google, they don't really pay attention to this. However, many SEO experts indicate different uses for them, and you can decide based on this outline:
- If the content is closely related to the root domain, use subdirectories like yoursite.com/blog.
- If the content is separate, like a new product or event, use a subdomain like product.site.com.
Now, let's discuss the differences between the ways they are configured:
How to configure a WordPress subdomain
Let's learn how to configure a subdomain in WordPress.
There are two main ways to do that in a WordPress installation. There is no right or wrong way; you just have to pick the method that best suits your needs:
- Different WordPress installations – this way, you will create a 100% separate WordPress installation in a subdomain. Imagine, for instance, a WordPress installation on site.com and another different WordPress installation on subdomain.site.com (or just a single installation in the subdomain). With RockStage, you can create a WordPress installation with a few steps and create your subdomain in a matter of minutes!
- WordPress Multisite – this way, you can use a single WordPress installation to add one or more subdomain sites. For instance, you may have site.com alongside sub.site.com and test.site.com under the same WordPress installation.
How to configure a WordPress subdirectory
Now, let's learn a bit about subdirectories.
Basically, a subdirectory already comes automatically configured in a WordPress installation. You just have to use the features of the framework to split your content into pages and organize them in different folders.
However, in case you wish to use different WordPress themes under the same installation — to edit the design of your pages, for instance —, you will need to use a Multisite.