Support » Fixing WordPress » Moving WordPress between different hosts and domains

  • I currently have a wordpress blog on

    I want to move this to and are hosted on two different hosts.

    This is what I did so far:

    Installed WordPress (using fantastico) on
    Downloaded wp-content folder of using FTP and uploaded it to
    Exported sql database of (from phpmyadmin)
    Replaced all occurrences of to (using notepad++)
    Imported this sql file to (using phpmyadmin)
    The problem now is…

    I am unable to login to using the username and password which was working fine when I installed.

    Another problem is when I point my browser to it displays the home page fine BUT when click on the pages, it throws a 404.

    One more weird thing I noted it, after importing the edited sql my new domain’s admin user name has got changed back to the username which was referred by my old domain. How could this be possible? I had to login to my new domain’s phpmyadmin and reset the password to be able to login.

    When I logged in… another surprise. I was able to see only ‘Dashboard’ and ‘Profile’ tabs. No other tabs (like Pages, Posts, Appearance, etc) were visible.

    Can someone come forward to help me out with this issue please? It is a client’s site so can not give out the original data. But if you can be kind enough to help me fix this, I can mail you the details.


Viewing 7 replies - 1 through 7 (of 7 total)
  • Try to follow the steps in the Codex:


    I did follow that. I will tell you in short what I did again:

    Assume the URL where I developed the site is and I want to move this to

    These are steps I carried out:

    1. Install a fresh wordpress (using Fantastico) in

    2. Downloaded the wp-contents folder from folder and uploaded it folder

    3. Exported the sql file from Used notepad++ to manually replace all occurrences of to

    NOTE: I know the documentation says “Use Search and Replace for WordPress Databases Script”. But at this point of time, I do not even have a DB yet on my So, when the script searches for “” in my new domain’s DB it will not find even a single occurance. That is why I had to replace it all manually using Notepad++

    TILL THIS POINT, everything is fine.

    4. I import the SQL to my new domain’s DB then

    -> the admin login username changes back to the admin name of my old domain’s blog
    -> The Admin email ID changes back to the admin name of my old domain’s blog
    *** This prevents me from logging onto the Dashboard

    -> The homepage works fine but the pages all give me 404

    -> I tried to manually change the admin username from phpmyadmin of my new domain. But the when I login, I only see the Dashboard and Profile tabs.

    I know the problem happens only after importing the sql but what do I do to fix it?


    3. Exported the sql file from Used notepad++ to manually replace all occurrences of to

    There is probably where the problem occurred. In the database, many of the values are stored in ‘serialized’ strings. The length of the string is stored along with the string. Unless the old and new strings are exactly the same length, the serialized string is broken and will not load properly.

    I have had good luck using the WP Migrate DB plugin to migrate a DB from one site to another. It processes serialized strings correctly.

    The only tricky part is that you must know the absolute file load paths of both sites as well as both URLs.

    The URLs are easy and here is an article that tells how to get the paths:


    Thanks for your reply. I am now going to start it over and try WP Migrate DB this time. It may take me another 4-5 hours.

    I will see if I managed to make it work this time and report back as well.

    Thank you!


    I tried it and guess what? That WP Migrate Plugin actually helped me solve half the problem.

    But then, now I can see the homepage fine. BUT, the pages are not loading. They give me a 404. Even if I try to view them from click on the “View” from Pages tab on the Dashboard, it still gives me a 404.

    Any idea how can I get over this?

    WooHoo!! this thread saved me –

    The trick is

    Set your Permalinks back to default and then try re-setting Permalinks back to what you want.

    All works fine now. Thanks so much!

    If your problem has been solved, please use the dropdown on the right to mark this topic ‘Resolved’ so that anyone else with this question can see that there is a solution.

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘Moving WordPress between different hosts and domains’ is closed to new replies.