# Fade Edges Generator > Fade the edges of an image or section to transparent with a CSS mask-image linear-gradient. Drop a picture (or pick an example), choose the sides and how far each fade reaches, see it over your page colour, then download the faded PNG or copy the CSS, an inline style or Tailwind classes. Free, no sign-up; the picture never leaves the browser. URL: https://fade-edges-generator.skillsafe.ai/ ## What it does, free, in the browser - Fades left and right, top and bottom, one side or all four; depth in % or px; edge opacity; linear or smooth curve. - Live preview drawn with the real CSS mask over a see-through, white, black or custom background. - Measures the picture's edges: warns when a fade covers busy detail, when a dark edge on a light page shows as a band, when little of the picture stays at full strength, and when px fades meet on a phone-sized image. - Downloads the faded picture as a PNG with real transparency (the same fade the CSS draws, multiplied into each pixel's alpha). - Writes `mask-image` and `-webkit-mask-image` (Safari), adding `mask-composite: intersect` / `-webkit-mask-composite: source-in` when two directions fade. - Reads mask CSS you already have (CSS, inline styles, Tailwind `[mask-image:...]` classes) and flags a missing `-webkit-` prefix or a missing `mask-composite`. ## The recipe Horizontal: `mask-image: linear-gradient(to right, transparent, black 15%, black 85%, transparent);` Vertical: `mask-image: linear-gradient(to bottom, transparent, black 15%, black 85%, transparent);` Write the same value in `-webkit-mask-image`. Softer edge: replace `transparent` with `rgba(0, 0, 0, 0.2)`. ## Optional AI step (metered, sign-in) Describe where the picture sits and how it should fade; the model returns fade settings with a reason for each change and placement steps. Only the settings, the page's measurements and the description are sent, never the picture. API: https://fade-edges-generator.skillsafe.ai/api.html (task "fade"). ## Source Adapted from the agent skill @mengto/css-alpha-masking (https://skillsafe.ai/skill/@mengto/css-alpha-masking) from mengto/skills by Meng To, MIT licence.