Without this tag, a phone treats your site as a tiny desktop page.
Direct answer
Add <meta name="viewport" content="width=device-width, initial-scale=1"> inside the <head>. It tells mobile browsers to use the device width and not zoom out to fit a desktop layout. Without it, media queries behave unexpectedly.
Example
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>My site</title>
</head>
What the parts mean
| Part | Meaning |
|---|---|
width=device-width | use the screen's real width |
initial-scale=1 | start with no zoom |
Avoid
user-scalable=noormaximum-scale=1, which block pinch-zoom and hurt accessibility.
Where Teyro fits
Teyro's Responsive Web Design with CSS course turns this into short lessons you can play in a few minutes a day. It has 100 lessons, and you can start free.
The bottom line
One line in the head makes responsive CSS work on phones.


