Skip to main content
Solved

How do I make a gradient blur?

  • August 17, 2023
  • 3 replies
  • 19112 views

How do I make the gradient blur like the picture below?

Best answer by Damian_Oczki

This exact effect is very difficult to do via CSS and pretty much impossible in Figma.

You can create something similar by having a “Background blur” layer masked by a gradient.

image

However, it’s not the same result as the one you’re asking for.

  • On your screenshot, the blur radius is changing from 0 (at the bottom) to some high value (at the top).
  • In Figma, the blur radius is constant. So you’re only fading an “solid blur” effect instead of having a true “gradient blur”.

There’s a way to make something exactly like the desired effect in CSS, but it involves having numerous blur layers, with increasing radii - and it’s a significant performance hit. Browsers (and Figma) weren’t meant to handle this approach, so open these links with caution:

Below is a screenshot of the “pattern” one. On the left is the realistic approach (the one you’re looking for), which needs hundreds of blur layers, moved 1px from one another. On the right is the cheaper approach, which only uses one blur layer, masked with a gradient, but it’s not the same effect (compare the sharpness of lines).

View original
This topic has been closed for comments

3 replies

Damian_Oczki
  • Active Member
  • 26 replies
  • Answer
  • August 17, 2023

This exact effect is very difficult to do via CSS and pretty much impossible in Figma.

You can create something similar by having a “Background blur” layer masked by a gradient.

image

However, it’s not the same result as the one you’re asking for.

  • On your screenshot, the blur radius is changing from 0 (at the bottom) to some high value (at the top).
  • In Figma, the blur radius is constant. So you’re only fading an “solid blur” effect instead of having a true “gradient blur”.

There’s a way to make something exactly like the desired effect in CSS, but it involves having numerous blur layers, with increasing radii - and it’s a significant performance hit. Browsers (and Figma) weren’t meant to handle this approach, so open these links with caution:

Below is a screenshot of the “pattern” one. On the left is the realistic approach (the one you’re looking for), which needs hundreds of blur layers, moved 1px from one another. On the right is the cheaper approach, which only uses one blur layer, masked with a gradient, but it’s not the same effect (compare the sharpness of lines).


Thanks for the answer!


  • 0 replies
  • August 22, 2023

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings