Streaming live at 10am (PST)

Image vs. Background Div | Best Practices

Hey everyone,
I’m working on my first Webflow project and this is essentially my first time doing the development myself (thanks to Webflow!). I wanted to get a better idea of best practices when it comes to using an image element versus a div with a background.

I’ve been opting for the DIV because it takes care of re-scaling and I don’t have to worry about the aspect ratio getting thrown off (ex. see the three cards in the middle of the page). However, the problem that I’m running into is that I have to create a combo class each time I want to use the same layout grouping but with a new image. Is this considered an acceptable practice? Should I have done this differently? Any other feedback on the site structure is appreciated as well.

Here is my site Read-Only:


Hey @yoon395

Using bg images is okey, but they are not SEO friendly and like you said you need to add combo classes.

Usually images that are part of the content must be real image elements < img >, and images that are just design elements can be bg elements.

Right now I’m working on a site and I’m using image elements for all images + backgrounds. The reason is SEO and image indexing.

The trick you can use to scale images properly it some custom CSS code:

 .image-class {
  object-fit: cover;

Learn more here >

Here’s a great article for images and Webflow >

Hope this helps :webflow_heart:


Very interesting. I’ll look into this further. Thank you!

1 Like

@yoon395 - I think Piter’s solution is more technically sound, but just throwing this out there as an option for using image elements while retaining a certain ratio without using custom code. Good luck on your first Webflow project!


Just looking for clarification, Does Webflow still make responsive images for inline images using object-fit? I love that Webflow automatically makes variants of inline images for different screen sizes, and Im not sure if using an object-fit class will override that feature