WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I had recently moved my wp site from a domain to other, but when I type in the new domain's address it gets redirected to the old domain/some_page.

Is this any common problem? Is there any known solution to this?

I had checked my code and it has no redirects to this page. Can someone give me a hand on this?

share|improve this question

migrated from stackoverflow.com Apr 3 '11 at 1:08

This question came from our site for professional and enthusiast programmers.

up vote 9 down vote accepted

This is because the URL settings inside WordPress are still pointing to the old WordPress site. In other words, you didn't read the Moving WordPress article in the documentation.

If your WordPress admin pages are still working, you can go to Settings → General, and change the WordPress URL and the Site Address to the correct values.

If your WordPress site is completely broken, then you can add the following values to wp-config.php, which will have the same effect:

define('WP_HOME', 'http://your_server/your_blog_url');
define('WP_SITEURL', 'http://your_server/your_wordpress_url');

Note that in most cases, the above two values will the same same, apart from exceptional circumstances.

share|improve this answer
I checked the above two steps... but even after when i load my url for the first time it takes me to the oldserver and when i load at second time it stays in new server.. is this a landing page sort or problem... – balanv Apr 2 '11 at 4:50
only my home page gets redirected.. all other pages are fine... – balanv Apr 2 '11 at 6:21

Give DNS 12-24 hours to propogate. Flush the DNS cache on your PC. Search your database with phpmyadmin for all occurrences of the old URL. Check your theme files for hardcoded URLs. Reset Dashboard>>Settings>>Permalinks.

share|improve this answer
Thankyou i got it...!! – balanv Apr 4 '11 at 5:43
What was the issue and what did you do to fix it? – markratledge Apr 4 '11 at 14:02
While copying the content from old to new server.. the landing page is set for old server got copied to newserver too.. so it resulted in redirection.. i removed the landing page, and the problem is cleared..!! – balanv Apr 5 '11 at 10:39

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

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