Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

WordPress

Petr Holusa
PLUS
Petr Holusa
Courses Plus Student 4,041 Points

How to set up mobile domain for wordpress website?

Hi,

I don't know how to ask correctly. I would like to archive somehow to get domain like m.domain.com for my website but I use Wordpress and responsive template. So is it necessary?

Thanks.

wordpress #domains #seo

1 Answer

Brian Hayes
Brian Hayes
20,986 Points

If you're website is fully responsive, then a subdomain with a CNAME such as "m.mywebsite.com" is not necessary. The use of a subdomain like that is for the sake of hosting a website that is specifically built for mobile phones but has the same content as the desktop website. A script is then used to detect mobile devices and redirect them from the main site at "www.mywebsite.com" over to "m.mywebsite.com".

In web development today, things have been shifting away from the old solution of separate websites since responsive design allows for easier management of the site, much better and easier to manage SEO, as well as better adaptivity to other screen sizes beyond a smart phone and desktop.

On top of that, responsive design has shifted to "mobile-first" design, which means you design for the smallest screen size, then through media queries and such, move up and up and up until you get to the biggest screen size you wish to support. This is just another nail in the coffin of the old "mobile websites".

Petr Holusa
Petr Holusa
Courses Plus Student 4,041 Points

Thanks to make it clear. You are absolutely right! I was thinking later about it if it's really necessary to do that in old way. Looks like I don't have to. Cheers! :)