Skip to content
  • home
  • portfolio
  • web design journal
  • blog
    • adventure
    • san diego
    • urbanity & architecture
    • projects
    • website design
Blog Web Dev Blurry Background Images in CSS

Blurry Background Images in CSS

By Forrest Smith - Drempd.com

There are a number of reasons why background image can look blurry in CSS, but recently I came across this issue that I haven’t noticed before — in part, because usually text doesn’t seem to be present, and so blurriness is a little less noticable.

Both the top and bottom screenshots in the image below here are exactly the same, with the exception of one CSS rule. Both are rendering the image (the pink background and black text) at the image’s native size (600px x 400px), and so there is no image scaling happening. Clearly, the top looks blurry, and the bottom much less so.

So what’s the difference? In the top image, the div that contains the image (the image is actually a background image of a div within the container div) is set to be 33.32% wide. In the bottom image, I rounded it to just be 33% wide. If I were scaling the image to match the width of the container, I could see the reason for the blurriness, but it’s quite odd that since I’m not scaling the image at all, that the fractional widths of the container would mess up the image.

Posted on July 1, 2023August 18, 2024 in Web Dev
  • Adventure

    • adventure
    • gravelgrinding
    • hiking
    • running
  • The Built Environment

    • architecture
    • urbanity
  • Locations

    • san diego
    • portland
  • Freelance Life

    • freelancing
    • productivity
  • Web Dev

    • css
    • entrepreneurship
    • git
    • handlebars
    • html
    • inkscape
    • photoshop
    • php
    • sass
    • web design
    • web development
    • saphire

drempd | san diego, ca


home contact

adventures san diego urbanity and architecture projects stream website design

portfolio resume san diego web design freelance web designer

custom web design responsive web design website maintenance