Webflow sync, pageviews & more.
NEW

What could be causing the spacing issue below images in the Webflow CMS collection display? The spacing only appears on a few images, not all of them, and I'm unable to determine the source of this issue. I've noticed a similar problem on another page with a similar design that also uses CMS collections. Any insights would be appreciated.

TL;DR
  • Inspect CMS content for invisible line breaks or empty text fields below images that may add unwanted spacing.
  • Set images to display: block and use object-fit: cover with consistent sizing to standardize layout.
  • Check for and remove extra bottom margin or padding on image wrappers and ensure consistent layout and visibility settings across all collection items.

A spacing issue below images in a Webflow CMS collection list—especially when it appears only on some items—usually points to content variability or layout settings inconsistencies among those items.

1. Check for Invisible Line Breaks or Paragraph Tags

  • CMS fields like Rich Text or Plain Text might include unintentional white space.
  • Some image entries may have empty paragraphs, line breaks, or hidden characters after the image—especially if you're using a Rich Text field sourced from the CMS.
  • Preview the actual CMS content to verify that there’s nothing unusual in the text fields below the affected images.

2. Inspect Image Display Settings

  • Go to the Image element settings in your collection item.
  • If the image is set to display: inline-block instead of block, it can sometimes introduce extra bottom space due to baseline alignment.
  • Set the image display to block to eliminate this default spacing.

3. Remove Extra Bottom Margin or Padding

  • Select the element wrapping the image and check for extra bottom margin or padding applied through:
  • Class styles
  • Combo classes
  • Inherited styles from parent symbols, components, or global settings
  • Also ensure you're not applying conditional visibility or spacing based on a CMS field that only triggers on some items.

4. Check for Text Nodes or Whitespace in CMS Content

  • If a Text Block or Rich Text element is conditionally visible (e.g., bound to a CMS field that is empty in some items), its container might still create vertical space.
  • Try temporarily disabling any conditional visibility to see if the spacing changes.

5. Inspect Layout Structure

  • Verify that all items in your Collection List share a consistent layout.
  • An inconsistent vertical alignment among flexbox settings, differing image aspect ratios, or missing elements in some CMS items may break the layout flow.

6. Check Image Aspect Ratios or Sizes

  • If some CMS images have different dimensions or inherent aspect ratios, they might stretch their container differently.
  • Apply object-fit: cover or set a consistent height and width (or use an aspect ratio box) to standardize layout.

7. Use Webflow’s Inspector Tool

  • Use Webflow’s Preview mode + Chrome DevTools to inspect the spacing next to each affected image.
  • This can reveal hidden margins or elements like <br>, empty <p>, or inherited CSS styles affecting only specific CMS items.

Summary

The excess spacing under some images is likely caused by either inline image display behavior, inconsistent CMS content (like invisible line breaks or empty text fields), or inconsistent layout or padding/margins applied via styles. Inspect the CMS entries and wrapping elements carefully, and set the image to display: block and use object-fit strategies to maintain visual consistency across collection items.

Rate this answer

Other Webflow Questions