loading...
Cover image for Dynamic text effects with css mix-blend-mode

Dynamic text effects with css mix-blend-mode

kaos profile image Kai Oswald ・1 min read

I recently discovered the css property mix-blend-mode, which describes how the text blends into the background, and started experimenting with it.
You can achieve dynamic text colors without adjusting the text-color manually. Even one single character can have multiple colors using this technique. This can lead us to some.. let's call them interesting .. results.

This pen uses mix-blend-mode: difference to invert the color on the background.

The background can also be transformed and animated.

When using the same text and background color, we can get creative and create reveal effects. In this specific pen, we've set the mix-blend-mode: darken to preserve the dark text.

A slightly more advanced method is used in the following pen. It uses a mask with a background image, fixed text and mix-blend-mode: color-dodge.

Browser Support

mix-blend-mode Browser Support

I'm excited about your comments and ideas how mix-blend-mode can be further (ab-)used.

Posted on by:

Discussion

pic
Editor guide