Support » Plugin: Simple 301 Redirects » [Plugin: Simple 301 Redirects] Can you redirect without using 'http://www..' ?

  • Jason Paul


    I’m in the process of switching an old site to a new WordPress site. I’d like to do all the 301 redirects on the dev site so they’re already in place when we re-point the DNS. I can see this being a problem as the dev site isn’t yet configured to have the correct full url. Is it possible to redirect using a relative path instead of the full url?

Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Author Scott Nelle


    Hi Jason,
    Relative paths work, but they have to be relative to the root of the domain. That is to say, if you install wordpress at then all of your destination urls will have to be either full URLs or start with /blog/. If WordPress is installed in the root you should have no problems.

    Jason Paul


    Thanks. I think that answers my question. Another fork of that question…
    If I do full path redirects on the dev server will they create any conflicts? Or will they snap into place and work when the dev site becomes the live site?

    (meanwhile the dev server still has a path like until DNS is repointed)

    Really just wondering if I should take the risk and wait to do the 301 redirects when the site is actually live and risk being crawled by Google and losing some clicks while updating links or if they can be done in advance.

    Plugin Author Scott Nelle


    I think I’m following you. If you use full path destinations on the dev site, the pages won’t work until you go live. That is to say, if you specify that /oldpathblabla.asp should redirect to, it will always go to the full path. so if you went to it would redirect you to the full path that you specified ( and not automatically figure out that you wanted

    Hope that answers your second question.

    It should be noted here that relative paths, while they work in most web browsers, are invalid according to spec. Therefore, they aren’t guaranteed to work in every application.

    Scott, a good solution would be, if a path started with ‘/’, automatically include the current domain in the Location header.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘[Plugin: Simple 301 Redirects] Can you redirect without using 'http://www..' ?’ is closed to new replies.