Shopify Collection Images Too Big on iOS? A Community-Driven Fix for Mobile Display

Hey everyone,

It’s a common headache for online store owners: you’ve got your Shopify store looking absolutely perfect on desktop, and even most Android devices, but then you check it on an iPhone, and suddenly things look… off. Specifically, images can sometimes decide they’re too important to fit and just blow up in size, especially your collection images. This isn’t just annoying; it’s a real conversion killer.

Recently, we saw a great discussion pop up in the Shopify Community forums about this very issue. Our fellow store owner, bigbraingames, was experiencing exactly this problem with their store, www.bigbraingames.co.nz, which uses the Horizon theme. Their collection images were appearing “super huge” on iOS Safari, pushing other content off-screen and forcing users to zoom out or scroll horizontally just to see everything. Not exactly the seamless shopping experience we aim for, right?

Understanding the iOS Image Sizing Challenge

The core of bigbraingames’s issue was that while desktop and Android displayed their collection images perfectly, iOS devices rendered them disproportionately large. This meant only half the image or collection grid was visible, making navigation frustrating. They even shared an image showing how odd it looked on iOS Safari:

Interestingly, when other community members like ProtoMan44 and Moeed checked the site on their iOS devices (an iPhone 13, specifically), they couldn't reproduce the issue. This often happens because of browser cache, different iOS versions, or even specific device resolutions. Their initial advice was to clear the browser cache, which is always a good first step for any visual glitch!

The Simple & Effective Fix: Theme Layout Settings

Here’s where bigbraingames discovered their own solution, and it’s a brilliant example of checking your theme’s built-in options first! They found that by simply changing the collection image aspect ratio setting in their theme layout from "auto" to "square", the images fit perfectly.

This is a fantastic insight because it leverages your theme’s native capabilities. Many modern Shopify themes offer options to control image aspect ratios (like square, portrait, landscape, or original/auto). When an image is set to "auto," the theme tries to display it at its original proportions, which can sometimes lead to unexpected overflows on smaller screens. Forcing a "square" ratio provides a consistent, predictable size that’s easier for responsive design to manage.

How to Adjust Your Collection Image Aspect Ratio:

If you’re facing a similar issue, this should be your first port of call:

  1. From your Shopify admin, go to Online Store > Themes.
  2. Find your current theme and click Customize.
  3. Navigate to the section where your collection images are displayed (e.g., "Collection list," "Featured Collections").
  4. Look for settings like "Image Aspect Ratio," "Image Shape," or "Image Size."
  5. Change the setting from "Auto" or "Original" to a fixed ratio like "Square" or "1:1".
  6. Save your changes and clear your browser cache (and your phone's browser cache!) before checking your store on an iOS device.

When You Need to Get Technical: Custom CSS Solutions

What if your theme doesn't have that specific setting, or the simple fix doesn't quite do the trick? This is where custom CSS comes in handy. Several community experts jumped in with excellent CSS suggestions that target iOS devices specifically.

Method 1: Comprehensive Mobile-First CSS

Mastroke provided a more extensive CSS snippet designed to specifically target devices with a maximum width of 749px (typical for mobile screens) and ensure collection images and their containers behave correctly, including using -webkit- prefixes for better Safari compatibility. This code snippet should be added to your theme's theme.css or base.css file.


@media screen and (max-width: 749px) {

  .collection-list__item img,
  .collection-list__item .media,
  .card--collection img {
    max-width: 100%;
    width: 100%;
    height: auto;
    -webkit-box-sizing: border-box;
    box-sizing: border-box;
  }

  .collection-list,
  .collection-list__grid {
    overflow-x: hidden;
    max-width: 100vw;
    -webkit-overflow-scrolling: touch;
  }

  .collection-list__item {
    max-width: 50%;
    -webkit-box-sizing: border-box;
    box-sizing: border-box;
    -webkit-flex-shrink: 0;
    flex-shrink: 0;
  }
  

  .collection-list__grid {
    display: -webkit-flex;
    display: flex;
    -webkit-flex-wrap: wrap;
    flex-wrap: wrap;
  }
}

This code ensures images don't exceed their container's width, maintains aspect ratio, handles potential horizontal scrolling for grids, and sets collection items to take up 50% of the width for a clean two-column mobile layout.

Method 2: Focused Image Sizing CSS

Another helpful tip came from eva_greene, focusing specifically on the image itself. This simpler snippet targets a common class for collection images and ensures they scale down correctly on smaller screens (up to 768px wide).

@media only screen and (max-width: 768px) {
  .collection-image {
    max-width: 100%;
    height: auto;
    object-fit: contain;
  }
}

This ensures any element with the class .collection-image resizes to fit its container, maintaining its aspect ratio and making sure the entire image is visible (object-fit: contain).

How to Add Custom CSS to Your Shopify Theme:

If you need to use these CSS solutions, here’s how you generally add them:

  1. From your Shopify admin, go to Online Store > Themes.
  2. Find your current theme, click Actions > Edit code.
  3. In the Assets folder, look for a file like theme.css, base.css, or sections.css.
  4. Scroll to the very bottom of the file and paste the chosen CSS snippet.
  5. Save your changes. Remember to clear your browser cache on your iOS device to see the changes.

A quick note: Always make a duplicate of your theme before editing any code. This way, if something goes wrong, you can easily revert to the previous version!

Wrapping It Up

Dealing with responsive design quirks, especially across different operating systems and browsers, is a common part of running an online store. The great thing about the Shopify community is that we can all learn from each other's experiences and solutions.

In this case, bigbraingames’s journey showed us that sometimes the solution is as simple as tweaking a theme setting, while other times, a bit of custom CSS might be necessary to get things pixel-perfect. Always start with the simplest solution (like theme settings or clearing cache) and work your way up to more complex code modifications if needed. And don't forget to test, test, test on actual devices!

Happy selling!

Share:

Start with the tools

Explore migration tools

See options, compare methods, and pick the path that fits your store.

Explore migration tools