Changing website link might be necessary if you change your business name or if you bought a new domain name. There are two ways on how to change the Magento URL:
Via Magento Admin Page
This process is the easiest and most convenient as it doesn’t need your website hosting access. It only needs your Magento admin logins.
Note: These steps are only applicable to Magento users with administration access. |
Step 1. Access your Magento admin page. Use the same admin URL set up during Magento installation.
Step 2. Log in using the username and password set up during Magento installation.
Step 3. Perform the Two-Factor Authentication.
Step 4. Click Stores on the menu bar on the left side of the page.
Step 5. Click the Configuration option.
Step 6. Click Web under General options.
Step 7. Enter the new website URL in the box provided under Base URLs.
Step 8. Enter the new website URL in the box provided under Secure Base URL.
Step 9. Click the Save Config button on the upper right side of the page to save the changes made.
Try accessing the website with the new URL. The changes should take effect right away.
Via PhpMyAdmin in cPanel
This process is applicable if you have access to your cPanel. Follow the steps below on how to change the Magento URL of your Magento website.
Step 1. Log in to cPanel.
Step 2. Click File Manager.
Step 3. Go to your Magento website files and locate the env.php file in the file path of app/etc/env.php.
Step 4. Right click on the file and select Edit.
Step 5. Click the Edit button.
Step 6. Scroll down to line 17 and take note of the value indicated on the right of the dbname (database name).
Step 7. Go back to cPanel homepage by going back to the previous tab.
Step 8. Scroll down to the icons under Databases and click phpMyAdmin.
Step 9. Click the database name that was obtained from Step 6.
Step 10. Click the table that ends with _core_config_data. The tables on each website can differ in prefix.
Step 11. Double-click the value of web/unsecure/base_url to edit the URL in the cell.
Step 12. Enter the new URL of your Magento website.
Step 13. Click anywhere outside the box to save the changes. A pop-up message shown in the screenshot below will indicate that the update has been saved.
Try accessing the website with the new URL. The changes should take effect right away.
Do not hesitate to contact our Singapore or Australia Support Team if you have further questions.