How to add www to WP site?

22 replies
My site that I recently set up in WP has http:// with no www. How can I add the www to it? Thanks.
#add #site #www
  • Profile picture of the author Bill D-G
    You don't need/want to do that. There is an effort underway to achieve canonicalization (see wiki as I can't post links yet) of websites. In a nutshell that means the powers that be (Google et al) are trying to avoid the duplication of web pages by omitting the "www" since it really is necessary now.

    So don't worry, be happy. Does that make sense?
    {{ DiscussionBoard.errors[4746672].message }}
  • Profile picture of the author bwh1
    Is that a WP hosted site?

    If at your host, this has nothing to do with WP.

    You have to do this in your domain setup. Now as you already HAVE the version without the www , you have to setup a 301 permanent redirect from the www. version to the no www version.

    Confused?

    http://yoursite is now life with a WP Blog setup

    http://www.yoursite is not yet active

    For Google those are 2 different things, so you have to go into your hosts admin panel to the DOMAIN settings, and set a redirect at the www. version, pointing it to the first option.

    After, people will always land at the http://yoursite version, regardless what they type into the browser.

    G.
    Signature

    Affiliates Wanted! Make anywhere from 42,- to $72 in commissions. Simply Recommend the Best QuickBooks Pro Video Course available at Clickbank.

    {{ DiscussionBoard.errors[4746675].message }}
    • Profile picture of the author katied772
      Originally Posted by bwh1 View Post

      Is that a WP hosted site?

      If at your host, this has nothing to do with WP.

      You have to do this in your domain setup. Now as you already HAVE the version without the www , you have to setup a 301 permanent redirect from the www. version to the no www version.

      Confused?

      http://yoursite is now life with a WP Blog setup

      http://www.yoursite is not yet active

      For Google those are 2 different things, so you have to go into your hosts admin panel to the DOMAIN settings, and set a redirect at the www. version, pointing it to the first option.

      After, people will always land at the http://yoursite version, regardless what they type into the browser.

      G.
      Is there a way to make sure it is like this when first setting up the site?
      Signature


      {{ DiscussionBoard.errors[4746691].message }}
  • Profile picture of the author Jesus Perez
    In Wordpress Admin > Settings > General, just make sure the WordPress address (URL) and Site address (URL) have the www. WordPress will do the rest.
    Signature

    {{ DiscussionBoard.errors[4746703].message }}
    • Profile picture of the author Chri5123
      Originally Posted by Jesus Perez View Post

      In Wordpress Admin > Settings > General, just make sure the WordPress address (URL) and Site address (URL) have the www. WordPress will do the rest.
      This ^ I have always done it like this and it works with no problems.

      Chris
      {{ DiscussionBoard.errors[4754182].message }}
      • Profile picture of the author puneet
        Originally Posted by Chri5123 View Post

        This ^ I have always done it like this and it works with no problems.

        Chris
        I have set up dozens of wp sites like this and never had a problem.

        It is 1st time I am facing a problem with this.
        Signature

        Please do not use affiliate links in signatures

        {{ DiscussionBoard.errors[4754217].message }}
  • Profile picture of the author bwh1
    Well

    this question can only be answered by You, or who set up the Blog.

    A domain alone is nothing and not accessible over the net, as there is nothing published on it.

    When you did the WP setup, you had to decide where you wanna do this.

    You choose to go for the //yoursite, so that let the www.yoursite empty.

    You could let it stay that way, but when somebody searches for your site with the www. they will see an error page.

    So better you use the www. version also and setup a redirect to the domain with the WP blog on it.

    G.
    Signature

    Affiliates Wanted! Make anywhere from 42,- to $72 in commissions. Simply Recommend the Best QuickBooks Pro Video Course available at Clickbank.

    {{ DiscussionBoard.errors[4746718].message }}
  • Profile picture of the author Riggs
    I'm not sure how to do it in WP, but you can achieve this by modifying the .htaccess file found in your FTP folder to say:
    RewriteEngine On
    RewriteCond %{HTTP_HOST} ^WWW*.YOURDOMAIN.*COM$ [NC]
    RewriteRule ^(.*)$ HTTP*://YOURDOMAINDOT*COM/$1 [R=301,L]

    Obviously remove the blue asterix' and replace the red text with your domain.
    Signature
    {{ DiscussionBoard.errors[4746720].message }}
  • Profile picture of the author WillR


    Go to your Wordpress settings and add in the 'www' on both lines above.

    Wordpress will then chuck you out of the dashboard and you will need to relogin but you will notice the domain now has the 'www' at the very beginning.
    {{ DiscussionBoard.errors[4746728].message }}
    • Profile picture of the author puneet
      Originally Posted by WillR View Post



      Go to your Wordpress settings and add in the 'www' on both lines above.

      Wordpress will then chuck you out of the dashboard and you will need to relogin but you will notice the domain now has the 'www' at the very beginning.
      This has worked very well for me in the past.

      Today, WP is behaving rather strangely. Once, I added the www in general settings it is not taking me to the login page again and login page is not coming up at www.mysite.com/wp-admin and there is no wordpress at www.mysite.com.

      All, I can see is some generic site (the one which you see once you register the domain and don't do anything with it)

      Can someone help me out with this.
      Signature

      Please do not use affiliate links in signatures

      {{ DiscussionBoard.errors[4754112].message }}
      • Profile picture of the author dv8domainsDotCom
        Originally Posted by puneet View Post

        This has worked very well for me in the past.

        Today, WP is behaving rather strangely. Once, I added the www in general settings it is not taking me to the login page again and login page is not coming up at www.mysite.com/wp-admin and there is no wordpress at www.mysite.com.

        All, I can see is some generic site (the one which you see once you register the domain and don't do anything with it)

        Can someone help me out with this.
        This might have to do with the aliasing of the domain on your hosting account or server Puneet; you can check to make sure that www. and non-www are "pointing" to the correct content folder (something like a www-root)

        Structure-wise, some servers have (relative to some arbitrary "user" folder, maybe):
        domain.com (point to some domain-root folder, we'll call /user/domain.com for now)
        www.domain.com would then "point" to /user/domain.com/www

        In which case, re-aliasing the domain or sub-domain to the correct content folder would help, alternatively enforcing a URL-based redirect through an .htaccess file (or an HTML or php-based redirect file, which are easy to correct but not 100% effective in all cases, depending on how the directory is accessed).

        If this doesn't work, there may be some URL's that are incorrect in the WordPress database itself (this requires phpMyAdmin access to check the DB directly; there are plenty of online guides for using phpMyAdmin to check the WP URL directly in the DB itself.)

        Hopefully one of the above helps.
        Signature
        Support a Warrior, Save Money!
        Rock Bottom Prices on Domains and Website Hosting
        {{ DiscussionBoard.errors[4757048].message }}
    • Profile picture of the author katied772
      Originally Posted by WillR View Post



      Go to your Wordpress settings and add in the 'www' on both lines above.

      Wordpress will then chuck you out of the dashboard and you will need to relogin but you will notice the domain now has the 'www' at the very beginning.
      By doing this, I will not need to do a redirect, right?
      Signature


      {{ DiscussionBoard.errors[4756898].message }}
      • Profile picture of the author UMS
        Originally Posted by katied772 View Post

        By doing this, I will not need to do a redirect, right?
        By adding that setting into WordPress, it automatically creates a redirect for you.
        {{ DiscussionBoard.errors[4756979].message }}
      • Profile picture of the author dv8domainsDotCom
        Originally Posted by katied772 View Post

        By doing this, I will not need to do a redirect, right?
        Correct, no redirect is needed as WP will take care of that for you. This actually stores it in the database.

        An .htaccess-based redirect will redirect all files referenced from the affected directories.
        Redirect via htaccess without updating the URL can effectively impose a redirect "loop", in a sense (so be careful in using it).

        as an example: htaccess rules enforce www.*, wordpress URL enforces non-WWW, which can possibly cause problems. Some host servers can compensate and correctly stop the loop, and some will refuse to serve any info at all.

        (I stick with the Wordpress URL at www (personal choice) and let the permalinks/canonicalization be handled by the WP admin, and avoid fiddling with .htaccess too much).
        Signature
        Support a Warrior, Save Money!
        Rock Bottom Prices on Domains and Website Hosting
        {{ DiscussionBoard.errors[4757000].message }}
  • It doesn't matter if your domain has WWW or http:// in front of domain name. Anyway people can visit your site typing www.yoursite.com or http:// yoursite.com
    {{ DiscussionBoard.errors[4747559].message }}
    • Profile picture of the author bwh1
      Originally Posted by Nino Rostomashvili View Post

      It doesn't matter if your domain has WWW or http:// in front of domain name. Anyway people can visit your site typing www.yoursite.com or http:// yoursite.com
      Only if ONE of those has a redirect to the other.

      Those are technically two different domains in Google's eyes.

      You could setup different content on //yoursite and //www.yoursite but I definitely wouldn't do it.

      G.
      Signature

      Affiliates Wanted! Make anywhere from 42,- to $72 in commissions. Simply Recommend the Best QuickBooks Pro Video Course available at Clickbank.

      {{ DiscussionBoard.errors[4749116].message }}
  • Profile picture of the author puneet
    Also, while creating the backlinks what one should follow?

    If your site is at http://mysite.com and www version is being redirected. Then the backlinks should be created to http://mysite.com or http://www.mysite.com or it does not matter at all.
    Signature

    Please do not use affiliate links in signatures

    {{ DiscussionBoard.errors[4754123].message }}
    • Profile picture of the author bwh1
      Originally Posted by puneet View Post

      Also, while creating the backlinks what one should follow?

      If your site is at http://mysite.com and www version is being redirected. Then the backlinks should be created to http://mysite.com or http://www.mysite.com or it does not matter at all.
      If you setup a 301 redirect, then it does not matter.

      Check out codes here 301 Redirect - How to create Redirects

      It's the same as if you would purchase a aged domain and redirect to your new domain over a 301.

      Google sees this as a "permanent moved" and forward PR and link juice.

      G.
      Signature

      Affiliates Wanted! Make anywhere from 42,- to $72 in commissions. Simply Recommend the Best QuickBooks Pro Video Course available at Clickbank.

      {{ DiscussionBoard.errors[4755253].message }}
  • Profile picture of the author lastreporter
    I agree with other posters. Don't add www. It is useless. The easier it is to get to your site -- the better.
    Signature
    {{ DiscussionBoard.errors[4756180].message }}
  • Profile picture of the author Ben Dixon
    Wow some crazy advice flying around in here.

    The way Puneet showed you with the screenshot is the best way to do that. And adding www is absolutely not useless depending on your circumstances.

    For example, some domain names e.g. yoursite.co are not always obviously a website when seen written like that as many people have never seen the .co domain extension. In this case adding www before your site is definitely a good idea.

    What you DO need to do is decide which you are going to use from the very beginning and stick with that. You need to set up your Google Webmaster tools and go to settings to specify which should be used by Google.

    When building backlinks always use only the one you have chosen.
    {{ DiscussionBoard.errors[4756437].message }}
  • Profile picture of the author Istvan Horvath
    Most likely you will... For people that do NOT type www ever (like me )

    If both URLs work - then search engines index both as two different sites!
    Signature

    {{ DiscussionBoard.errors[4756962].message }}
  • Profile picture of the author timpears
    The http:// or www. doesn't seem to matter. I go to lots of sites by typing in the domain name in the address slot. I don't bother with anything prior to the '.' and the site will resolve every time.

    But if you really need to have the www in the address bar, then do as Will suggested. That will take care of it.
    Signature

    Tim Pears

    {{ DiscussionBoard.errors[4757123].message }}

Trending Topics