Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

To make a website work well on phones, start with flexible content and a simple narrow-screen layout, then add columns and spacing only when the content has room. Set the mobile viewport correctly, use media queries for page-level changes and container queries for components, and test the layout across intermediate widths—not just a phone and a desktop preset.

What makes a website responsive?

Responsive design is an approach to layout, not a single CSS property or a collection of templates for specific devices. HTML in normal document flow can reflow as space changes; fixed-width layouts can force horizontal scrolling on narrow screens and leave excessive empty space on wide ones. MDN describes responsive web design as “an approach,” built around adapting content and layout to the available space: MDN’s responsive design guide.

Build the narrow layout first. Use normal flow, flexible Grid or Flexbox tracks, and relative sizing. A single column is often a useful starting point on a narrow screen; introduce extra columns on wider screens only when the content remains readable.

Set the mobile viewport

Add this tag inside the document’s <head>:

<meta name="viewport" content="width=device-width">

Without a suitable viewport setting, a mobile browser may use a wide virtual layout viewport, so narrow-width media queries do not behave as expected. MDN recommends width=device-width to match the viewport to the device width: MDN’s viewport reference. initial-scale=1 is common but often unnecessary; it can be appropriate if overflow causes unwanted initial shrinking. Do not prevent users from zooming.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
#1 Best Overall
Yojaro 4Pack Silicone Suction Phone Case Mount, Silicon Adhesive Smartphones Stand Sticky, Hands-Free Phone Accessories Holder for Selfies and Videos (Black & White & Translucent & Light Pink)
  • 【Strong Adsorption】The inspiration of the silicone phone suction case comes from the adhesive force of the octopus. Each suction cup phone mount is 3.15 inches long and 2.17 inches wide, with 24 independent suction cups providing a stronger and more stable suction force, so you don't have to worry about your phone falling during use.
  • 【Back of Phone Suction Grip】Remove the adhesive film on the phone suction cup and stick it on the phone case. You can then fix the phone on any smooth surface, which is very convenient. (The phone suction cup cannot be removed and reused after being attached to the phone case. It is recommended to attach it to a regular phone case, not a valuable one.)
  • 【Widely Used】Our non-slip silicone phone sticky grip mount attaches to almost any flat phone case and make it compatible with common mobile phones such as iPhone and Android.You can shoot, watch videos or video calls in the kitchen, gym, dance studio, bathroom and other places.
  • 【Capture the Wonderful Picture】Whether you are a TikTok creator or just like to share videos and photos, this phone suction cup can help you hands-free capture wonderful videos and photos for sharing with friends.
  • 【Note】You can fix the phone suction cup on a smooth surface such as a mirror or glass. If necessary, wipe the suction cup with a damp cloth to obtain stronger suction. Before releasing your hand, make sure the phone is firmly fixed. (Not applicable to rough walls, wooden surfaces, and other uneven surfaces)

Build the layout with flexible CSS

Let available space—not a fixed page width—determine how content fits. Constrain images so they shrink to fit their containers without being enlarged beyond their intrinsic size:

img {
  max-width: 100%;
  height: auto;
}

For a page that becomes two columns when there is enough room, keep the default layout single-column and add a content-driven media query. This example’s 48rem breakpoint is illustrative, not a universal phone or tablet threshold:

Rank #2
Apple EarPods Headphones with USB-C Plug, Wired Ear Buds with Built-in Remote to Control Music, Phone Calls, and Volume
  • SUPERIOR COMFORT — Unlike traditional circular ear buds, the design of EarPods is defined by the geometry of the ear. Which makes them more comfortable for more people than any other ear bud–style headphones.
  • HIGH-QUALITY AUDIO — The speakers inside EarPods have been engineered to maximize sound output and minimize sound loss, which means you get high-quality audio.
  • BUILT-IN REMOTE — EarPods with USB-C plug also include a built-in remote that lets you adjust the volume, control the playback of music and video, and answer or end calls with a pinch of the cord.
  • COMPATIBILITY — Works with all devices that have a USB-C port.
  • INTEGRATED MICROPHONE — A built-in microphone precisely captures your voice while you’re on the phone, taking a FaceTime call, or summoning Siri — so you’re always heard loud and clear.
.page {
  width: min(100% - 2rem, 72rem);
  margin-inline: auto;
}

.layout {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
}

@media (width >= 48rem) {
  .layout {
    grid-template-columns: minmax(0, 2fr) minmax(14rem, 1fr);
  }
}

Choose a breakpoint when the actual content begins to feel cramped or the layout stops working. Prefer relative units and check widths around the breakpoint rather than choosing a number simply because it matches a popular device. MDN’s guidance on responsive design and media queries explains these layout decisions.

Choose between media queries and container queries

Use a media query when a page-level layout needs to respond to viewport or device conditions. Use a container query when a reusable component should respond to the space available in its own containing element. A card in a sidebar, for example, may have less room than the same card in a main column even though the viewport is unchanged.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
Rank #3
PopSockets Adhesive Phone Grip, Holder- Black
  • Secure Hold: Our PopSockets adhesive phone grip gives your cell phone a secure, comfortable hold in hand to help prevent drops while texting, taking photos, or scrolling on the go. Designed to stick firmly to most phone cases and devices.
  • Hands-Free Made Easy: Easily turn your PopSocket into a phone stand to prop up your phone anywhere, perfect for watching videos, video calls, or following recipes. A must-have phone holder that keeps your device secure and ready for anything.
  • Compatibility: Works with all phones, tablets, and Kindles. Sticks best to smooth, hard plastic cases and may not adhere to silicone or textured cases. Easily swap your PopTop to change up your style.
  • Black PopSockets: Simple, refined, and endlessly versatile. A timeless essential for any phone.
  • Travel Must-Have for People On the Go: A must-have travel accessory for flights, flying, airports, air travel, airplanes, planes, international trips, cruises, and long travel days. Key gadget for your airport haul, travel accessories and must-haves.
Layout need Technique What determines the change
Page columns change as the screen gets wider Media query with Grid or Flexbox Viewport conditions
A reusable card changes when its parent column changes Container query Its containing element
Content should resize smoothly within limits Fluid sizing and flexible tracks Available space, without a breakpoint at every width
Mobile layout behaves as if it has a wide viewport width=device-width viewport meta tag The layout viewport matches the device width

Media queries for page-level changes

Media queries can test viewport width and height, orientation, resolution, and user preferences such as reduced motion. Use them when the condition applies to the overall viewing environment, and keep each rule tied to a real layout or usability need.

Container queries for reusable components

Set up a size-query container, typically with container-type: inline-size, then style a descendant with @container. For example:

Rank #4
360° Rotating Stainless Steel Phone Tether Tab (Silvery 3-Pack) - Universal for iPhone & Other Phones (Fits Wristbands/Necklaces/Crossbody Straps)
  • [360 ° Flexible Rotation Design] Comes with a rotatable lanyard ring that supports 360 ° free rotation, effectively solving the problem of twisted and tangled lanyards
  • [Wide compatibility] The ultra-thin 0.02-inch design does not block the charging port at all, and both wired and wireless charging can be used directly without removing the pad. Compatible with most smartphones such as iPhone, compatible with various wristbands, lanyards, crossbody straps, and keychains
  • [Durable and Portable Material] Premium rust-resistant stainless steel material with good flexibility, which not only avoids scratching the phone case, but also has excellent anti rust and anti fading performance
  • [Multi scenario Practical] Paired with a lanyard or wristband, hands-free use can be achieved. The phone is within reach and not easily dropped, ideal for daily commuting and outdoor activities. Suitable for full coverage phone cases, does not support half coverage phone cases
  • [Quality Service] If you find any damage or other issues with the product upon receipt, please contact us immediately. We will handle it quickly
.card-list {
  container-type: inline-size;
}

.card {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
}

@container (width > 42rem) {
  .card {
    grid-template-columns: 10rem 1fr;
  }
}

Here the card switches to a side-by-side layout only when its container is wide enough. Check browser support for the environments you need to serve; if container queries are not supported in a target environment, Grid, Flexbox, and viewport-based media queries can provide alternatives. See MDN’s container query guide.

Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Support on Ko-Fi

Test the site at real layout widths

Resize through intermediate widths instead of checking only a named phone and desktop preset. Test with the actual content, since long labels, words, or form controls can expose problems that short sample text hides.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
Best Value
Anteel 2 Pack Silicone Suction Cup Phone Case Mount Double Sided, Hands-Free Silicon Phone Grip with Higher Suction Power for Selfies and Videos, Non Slip Phone Accessories (LightPink&White)
  • 【PKYAA Double Sided Silicone Suction Phone Case Mount】PKYAA With Double Sided 40 Strong and Reliable individual suction cups, PKYAA provides a thicken and upgraded universal silicon suction mount for your phone.
  • 【Friendly to Content Creators】If you are a content creator or an online influencer, you can create videos anywhere with this suction mount completely hands free with this silicone cell phone mount for cases.
  • 【HANDS-FREE & Adhere to Mirrors】This Double Sided silicone suction phone case mount allows you to stick your phone to the mirror easily. No longer holding your phone in one hand to watch video tutorials while making up.
  • 【Strong Grip on the Smooth Surface】You can easily hang your phone anywhere with a smooth surface. All you do is you clean off your phone and smooth surface. It is STURDY and it not only sticks to mirrors, it also sticks to windows, it sticks to refrigerators, tiles and other clean, flat surfaces.
  • 【Press Down Firmly Every 30 Minutes】Use your palm or fingers to press the phone down firmly and check it's secure before letting go. Apply even pressure for a few seconds to allow the suction cup to adhere properly. To maintain the grip and prevent accidental falls, it's a good practice to periodically reapply pressure to the suction cup.
  • Check that navigation, forms, images, cards, and long words do not overflow horizontally.
  • Check portrait and landscape layouts where orientation changes how content fits.
  • Verify that text and controls remain usable and that users can zoom.
  • If styles depend on user-preference media features, check those conditions too.
  • Confirm that content reflows at narrow widths. For the criterion’s exact requirements and exceptions, consult the W3C WCAG 2.2 Understanding page on Reflow.

Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.