Base64 images: when to inline them (and when not to)
Base64 data URIs save a request but cost caching, lazy loading and render speed. Measured sizes, the cases where inlining helps, and why SVG should be URL-encoded instead.
Author
46 articles
Base64 data URIs save a request but cost caching, lazy loading and render speed. Measured sizes, the cases where inlining helps, and why SVG should be URL-encoded instead.
How to put an SVG in a CSS background as a URL-encoded data URI, which characters to encode, why it beats Base64, and how to recolour icons with mask and currentColor.
How linear, radial and conic gradients work in CSS, with copy-ready code for stripes, pie charts, text overlays and gradient borders, and how to stop blends turning muddy.
How palette extractors pick colours from a photo with k-means clustering, why they miss small accent colours, and how to turn the result into an accessible web palette.
Organic blob shapes need only one line of CSS. How the eight-value border-radius syntax works, which values look good, how to animate a morphing blob, and when to use SVG instead.
What every letter in an SVG path's d attribute means: move, line, cubic and quadratic curves, arcs and close path, absolute versus relative coordinates, and how the arc flags work.
Add a frosted glass effect to an Elementor container with a few lines of CSS. Steps for Elementor Pro and the free version, with code to copy and fixes for when it doesn’t show.
Nineteen new free tools for images, fonts, CSS effects and design mockups, plus a Paste into option that rewrites CSS for WordPress, Elementor, Divi, Bricks and Breakdance.
Four CSS button hover effects to copy (shine, fill, animated border and lift), how the pseudo-element technique works, and the accessibility details most snippets miss.
Enjoying Refract Tools? ☕️
Refract is a personal project built to make design and development a little easier, with practical, intuitive tools that help you work smarter, without AI doing the work for you.
If you find the tools useful, consider buying me a coffee. Every bit of support helps me keep building, improving, and sharing more free tools with the community.
Thanks for being here! ❤️
Buy me a coffee