How to configure a dedicated IP address to show the website

If you wish to have your website accessed via the IP address-based link, the first thing you need is a dedicated IP address.

On our Shared packages one main server IP address is used by different cPanel accounts on it, thus, it is not possible to assign your domain to it. In such cases, you can purchase a dedicated IP address that allows having a unique server IP address for your account on Shared server.

PLEASE NOTE: due to certain technical restrictions, it is possible to assign only one dedicated IP address to a single cPanel account on Shared server.

On VPS and Dedicated servers, you can create multiple cPanel accounts and assign different dedicated IP addresses to them. You can find detailed instructions on how it can be done here.

NOTE: Though VPS and Dedicated servers have a dedicated IP address assigned to the plan, it resolves the content of a cPanel account's primary domain. Thus, it is required to order another dedicated IP address.


How to change website links for WordPress website

There are two main ways to set the IP address as a website link: via WordPress admin dashboard and via website database.

To change the website URL in your WordPress admin dashboard, please follow these steps:

1. Log in to the WordPress admin panel >> go to the Settings menu >> General.
2. Update WordPress Address (URL) line and Site Address (URL) lines and save the changes:

To change the website URL in your website database, please follow these steps:

1. Locate the database name in wp-config.php file.
2. Go to cPanel >> Databases section >> phpMyAdmin menu:


3. In the list of databases, locate the name of your website database and click on it. Then, select wp_options table (wp_ is the database prefix and it can be different for your installation):


4. Choose the siteurl and home options and enter the desired IP address instead of the domain there:


Once done, you can enter the IP address in the browser and see the content of your website:


How to assign a certain domain to the IP address

NOTE: In case the account contains multiple websites hosted in it, the IP address gets assigned to the main domain by default.

If you wish to have a certain domain to be redirected to a dedicated IP address in your account, please follow these steps:

1. Locate the .htaccess file inside the public_html folder in cPanel >> File Manager menu. If there is no such, you can create it using this tutorial.
2. Click on the file and choose Edit at the top bar:

Add the following rule to the file and click Save Changes:
RewriteEngine on
RewriteCond %{HTTP_HOST} ^111.111.111.111$
RewriteCond %{REQUEST_URI} !^/subfolder/
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ /subfolder/$1
RewriteCond %{HTTP_HOST} ^111.111.111.111$
RewriteRule ^(/)?$ subfolder/index.php [L]

The .htaccess file with the above rule should look this way:

3. Change the domain/subdomain root directory to a subdirectory of public_html. For instance: ~/public_html/addon.com.
Feel free to follow the steps from this guide to update the website directory root.

4. Update all the "subfolder" values of the rewrite rule (Step 1) in the /public_html/.htaccess file with the created addon/subdomain root directory (Step 2).

NOTE: If the addon/subdomain root directory is set to ~/addon.com and it should not be changed, you still may create a symlink from ~/public_html/addon.com to ~/addon.com using the following guide. The rewrite rule inside the ~/public_html/.htaccess file should still be present.

After adding the rule to the .htaccess file of the domain`s root directory, the needed addon/subdomain will be redirected to the dedicated IP address in the browser.

That's it!

Need any help? Contact our HelpDesk
Updated
Viewed
20689 times

Need help? We're always here for you.

notmyip