So, for the longest time my wordpress website has been www.nameofwebsite dot com. Now, when I am in my website the url is nameofwebsite.com So, the www all of a sudden has been taken out. When I type the address www.nameofwebsite.com it get redirected to nameofwebsite.com Why has this happened? My hoster said that they can change it to the www URL address, but I want to know if by doing this whether it will affect my page rank, SEO if the URL gets changed again. Furthermore, there must have been a problem for the url address to suddenly be changed. Does anyone know why it would get changed, and whether its best to leave as is, or to have the www put back in the URL through my hoster. Hope this makes sense - I am very much a newbie! Thanks for your help!!!
Most likely via DNS changes -- did your host say they made changes to your DNS? Changing it back to www. should not affect your rankings.
In Wordpress Admin panel Settings >General >Wordpress Address (URL ) & Site Address ( URL ) Put your website url in both the boxes with www included
www.yoursite.com is a subdomain of yoursite.com. They changes something, but it really makes no difference - you should be able to get to the site with or without the www.
How would someone go about changing this in the DNS exactly? For the OP, you want to have one or the other, www or non-www. You should have the option to run whichever you want, it's not something the host generally has control of. You can also set this in your Google Webmaster Tools account to remove the www. To answer your question, it is not going to hurt your ranking to have one or the other, you just don't want both options. This is usually solved in the wordpress admin panel like someone mentioned, or you can add a few lines of code to your .htaccess file to control your URL.
You can get it changed through your hoster, the good news is that it won't affect your website's page rank or other rankings.