After migrating subdomain to new domain, not sure if the subdomain got left over in any of the settings.

Where in PHPmyAdmin / SQL database should I find those subdomain urls and update them to the new one?

(not even sure if my question makes sense).

Any help will appreciated

4 Answers 4


i think you mean updating permalinks and its in wp_options table

go to your host control panel (cpanel/directadmin) and phpmyadmin from there find your database and update site url and website address from wp_options table

  • Hi sorrow poetry thank you for the answer. Will try your suggested way.
    – alanw
    Commented Jul 29, 2017 at 2:41

Go to your database and open the wp_options table. There should be 2 settings siteurl and home that need to be updated with your new domain. You will also have to update all the permalinks in your database from your old domain to your new domain.


You can set this in wp-config.php if you are facing redirect issues after migration.

define( 'WP_SITEURL', 'http://example.com' );
define( 'WP_HOME', 'http://example.com' );

After migrating you have not only to worry about the site's URL (like WP_SITEURL and WP_HOME), but for every single link you use in your posts and pages that targets one of your own posts and pages. They will all direct to the wrong URL.

My advice is to always use a dedicated tool for that and follow what is written on WordPress.org about that topic. Even there, see under "Changing Your Domain Name and URLs", they recommend a "Search and Replace for WordPress Databases Script" to safely change URLs.

So my advice would be to not use PHPMySQL for that, but a dedicated script. But if you insist on PHPMySQL, then go with sorrow poetry's answer, but do not forget links inside your posts and pages, which you can both find in wp_posts.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.