Transferring domains, I migrated a WordPress database using the export/import functions in phpmyadmin.

Everything worked as intended, until I tried to change permalink appearance in the WP dashboard. Since then, all posts have disappeared from the Posts tab in the WP dashboard. The posts still exist in the DB.

Measures I have tried already:

  • Reimporting the DB from my backed up version.
  • Changing permalink structure back to what it was originally.
  • Running the WordPress database table repair protocol. (It reported no issues).
  • Disabling all plugins.
  • Changing the theme to twentyseventeen.

I even tried importing the DB on a fresh install of WP to see if the posts would show up. Even without modifying the permalinks, they do not.

I can create new posts and they show up in the dashboard without any problems. The permalinks also display properly. I can also visit the old permalink-style URIs of the existing posts and they display properly.

Any further ideas on what to try would be great. My client has existing content they do not wish to lose editing privileges to in the dashboard. Thank you!

  • Did you run a search and replace on the database after the import into PHPMyAdmin?
    – user2015
    Jul 7, 2018 at 21:13

1 Answer 1


A great tool for WordPress database and domain migration is Search-Replace-DB. It does all the rename work for you and even takes care of serialized data.

You can find here.

What you should do:

  • Clear the whole database in the target system you fiddled around with.
  • Drop all tables, so that you have an empty database.
  • Re-import the untouched original database from the old domain.
  • Download the three PHP files from SRDB.
    • index.php
    • srdb.class.php
    • srdb.cli.php
  • Upload them in an extra directory in the same folder as your WordPress installation, like ./srdb
    • It should look like:
    • ./srdb
    • ./wp-admin
    • ./wp-content
    • ./...
  • Open it in the browser via http://new-domain.com/srdb

You should see something like this:


Database credentials should be detected automatically. If not, you put it in the wrong place.

  1. Enter your old domain url
  2. Enter your new domain url
  3. Do a dry run to see if it works.
  4. Do a live run to replace.

Note: This only takes care of the database. If you have domain names hardcoded in your theme files, like CSS, PHP or JS, you have to manually search and replace them.

Hope this helps.

  • As an addition to Mario's answer, there is a chance you might be able to run WP-CLI commands on your host. Either your hosting provider allows you to use the console and/or provides you with SSH credentials. If so, there's a strong chance WP-CLI library is installed and you can use wp search-replace command. The CLI is much better and faster for migrating your database than any other plugin. Apr 6, 2021 at 8:35

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.