Making WordPress Always Use WWW

Making WordPress Always Use WWW

With WordPress, you can easily customize your site, including making your WordPress links always use www or without using www.

The purpose of this tutorial is to show you how to make your WordPress page links always use www even if they were previously accessed without it.

For example, when you access wpgan.com, the page will automatically show www.wpgan.com in the address bar when it opens.

Cara Membuat WordPress Selalu Menggunakan WWW - 0-0

But it looks a bit strange if the website name is www.wpgan.com (too many w's), so you can adjust this address according to your own preference, whether you need to use www or not.

How to Make WordPress Always Use WWW

Note: Before doing this, make sure you back up your website so that if an error occurs, you can restore the website to its original state..

There are many ways you can make your WordPress links always use www. However, there is one very important thing you need to pay attention to, which is that www and the main domain must point to the same IP, or www must be pointed to the main domain using a CNAME (please contact your hosting or domain provider to confirm this if you are not sure).

Then what about subdomains, does the www of the subdomain have to be the same as the main domain?

No, if you are using a subdomain, for example demo.wpgan.com, you can point www.demo.wpgan.com to demo.wpgan.com using a CNAME, or point it to the same IP as demo.wpgan.com.

Have you adjusted your DNS? Now you can try some of the following options to make WordPress always use www.

Option 1: Install WordPress With www

If you are just about to install WordPress, you can install it directly with www. For example, if you are using Softaculous, you can directly select the www option.

Cara Membuat WordPress Selalu Menggunakan WWW - 1-1

However, if you are not using Softaculous to install WordPress, you can use other options.

Option 2: Using WordPress Manager

If your hosting has a WordPress Manager feature, you can use that feature to update your www settings.

To use WordPress Manager and scan for installations, you can follow this tutorial: How to Rescan WordPress Installations in Softaculous.

After the WordPress installation has been successfully scanned, you can open or expand the WordPress installation details, then in the Website URL option, add www to the URL and save it so it looks like this

Cara Membuat WordPress Selalu Menggunakan WWW - 2-1

Option 3: Using Softaculous All Installations

Much like WordPress Manager, if the installation is not detected in Softaculous, you can scan for the WordPress installation first by following this tutorial: How to Rescan WordPress Installations in Softaculous.

After the installation is detected, you can go to the Softaculous All Installations page in your hosting.

Cara Membuat WordPress Selalu Menggunakan WWW - 3-1

Once you are on the all installations page, edit the WordPress site you want to change to always use www.

Cara Membuat WordPress Selalu Menggunakan WWW - 3-2

Finally, in the URLsection, change the link so it uses www. For example, from https://wpgan.com to https://www.wpgan.com then save the changes.

Cara Membuat WordPress Selalu Menggunakan WWW - 3-3

Option 4: Using WordPress Settings

Does your hosting not support Softaculous or WordPress Manager? Then you can change the URL directly through the WordPress settings page.

Please log in to WordPress as an admin, then open the dashboard page.

After you are on the dashboard page, you can open the menu Settings > General

Cara Membuat WordPress Selalu Menggunakan WWW - 4-1

Once you are on the General page, you can change the WordPress Address and Site Address from without www to with www, then save the changes. If successful, you will be redirected to the login page to log in again.

Cara Membuat WordPress Selalu Menggunakan WWW - 4-2

Option 5: Via Database

This method is not recommended if you are a beginner or do not know the basics of databases. If you do not know anything about databases, it is recommended to use another option.

To use this method, please open the database management page on your hosting or server, for example, if you are in cPanel, you can use phpMyAdmin.

Cara Membuat WordPress Selalu Menggunakan WWW - 5-1

After you are on the phpMyAdmin page, select or open the database used for your WordPress installation, for example, here it uses the database username_wp456.

Cara Membuat WordPress Selalu Menggunakan WWW - 5-2

Find and open the table named prefix_options (the prefix here is a different prefix for every WordPress installation, so to make it easier, you can search for the table _options)

Cara Membuat WordPress Selalu Menggunakan WWW - 5-3

In the Option Value siteurl and homefields, double-click and change them so the URL uses www.

Cara Membuat WordPress Selalu Menggunakan WWW - 5-4

Conclusion

To change your WordPress links to always use www, you can use various methods depending on the tools available and how well you understand WordPress management.

Because if you make a mistake, for example when using the database editing method, your changes could actually cause the website to error when accessed.

Written by

Muhammad Khoirun Nasikin

I enjoy tinkering with WordPress, hosting, VPS, web development, and various small experiments related to websites. I have over 3 years of experience in the web hosting industry.

COMMENTS

Loading...