You must have faced this issue when accessing your WordPress admin page, which redirects to a different domain. So, in this article, we have listed some solutions that may help you resolve this issue.
Solution 1
Check for Redirection Rules in the .htaccess File
1. Log in to your cPanel account.
2. Click on File Manager.
3. Open the public_html directory.
4. Right-click on the .htaccess file and click on Edit.
If there is any code for the redirection rule, remove it and Save the file.
Solution 2
Update WordPress Config File
- Log in to your cPanel account.
- Open the File Manager.
- Open the public_html directory and edit the wp-config file with the lines given below –
define( 'WP_SITEURL', 'https://www.example.com');
define( 'WP_HOME', 'https://www.example.com');
Note
Replace htttps://www.example.com with your actual URL.
4. Click the Save Changes button once you have added the lines.