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!
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

Peaches Stubbs
21,320 PointsMedia Queries / Mobile Design
Hey everyone I recently built a site oacbahamasinc.org I used media queries. When I test the site on my computer it works fine. I adjusts when I resize the screen. However when I open it on my phone I get the regular site.
I am sure that I am missing something here. What do I need to use other than media queries to make my website mobile friendly.
4 Answers

Julian Gutierrez
19,201 PointsHave you included:
<meta name="viewport" content="width=device-width, initial-scale=1">

edeharrison
Full Stack JavaScript Techdegree Student 11,127 PointsHi Peaches,
You just need to put this code inside your header in the html to make it work:
<meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, user-scalable=no"/>
All the best,
Ede

Peaches Stubbs
21,320 PointsThank you so much everyone, I will try it out and update you all in a few days.

Peaches Stubbs
21,320 PointsJust letting you all know that including that 1 line of code allowed my media queries to kick in properly. Thank you all !

Fynn Lehnert
15,244 Pointsand check for elements that might be bigger than your screen. that always breaks the layout! the chrome devtools really help there