Welcome to the Treehouse Community

The Treehouse Community is a meeting place for developers, designers, and programmers of all backgrounds and skill levels to get support. Collaborate here on code errors or bugs that you need feedback on, or asking for an extra set of eyes on your latest project. Join thousands of Treehouse students and alumni in the community today. (Note: Only Treehouse students can comment or ask questions, but non-students are welcome to browse our conversations.)

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and a supportive community. Start your free trial today.

CSS Responsive Layouts Media Queries Creating Breakpoints

Lisa Weil
Lisa Weil
4,919 Points

Media Query breakpoints work great when I minimize and maximize but not when I Inspect my code with Dev Tools?

The media queries on my website are working great when I minimize and maximize the browser, however, whenever I go to inspect it, it will not show the mobile version when I change the viewport to iPhone or Galaxy. Does anyone know why it works fine on desktop but not in Dev Tools?

Robert Schaap
Robert Schaap
19,836 Points

Is your site online somewhere or could you post some of your code?

1 Answer

Cody Reed
.a{fill-rule:evenodd;}techdegree seal-36
Cody Reed
Front End Web Development Techdegree Graduate 19,268 Points

I would double check your <meta> tag's viewport configuration placed inside the <head> tag of your HTML if your breakpoints are working outside of Dev Tools.

I've included and example that might help solve your problem:

<meta name="viewport" content="width=device-width, initial-scale=1.0">

Happy coding.