DEV Community

Cover image for Text Mask in Figma: A Simple Guide

Posted on

Text Mask in Figma: A Simple Guide

Masking is one of the easiest techniques to control visual elements in your design. It is a tool not exclusive to Figma; every other design tool worth its salt has a masking feature.

This tutorial will help you learn the basics of masking, how to mask text in Figma, and some more ideas you could practice to elevate your design skills in Figma.

Introduction to text masking effect

Many brands have utilized text masking effects to create stunning designs. You probably have seen creative Google doodles on its homepage. Many of these use text masking to elevate their text.

Google Doodle for 44th Anniversary of the Birth of Hip Hop (Source)

The MCU movie title cards extensively use text masking to create catchy visuals.

Marvel's Avengers Infinity War Title Card

Marvel's Avengers Infinity War Title Card (Source)

See how captivating these images are? They actually are pretty easy to implement once you understand the basic principle behind text masking.

What is masking?

Imagine spray painting on a plain wall using a heart stencil. What would be the end result? You get a beautiful heart painted on the wall. It can be any color, design, or pattern.

Here the stencil acts as your mask – it determines how much of the fill or spray is actually painted.

A simple depiction of how text masking works with the example of stencil and spray paint

This is the fundamental idea behind masking – it lets you show a specific area of an image while hiding the rest.

There are two basic layers involved in masking.
1. Mask layer
2. Content layer

The mask layer acts like a filter that determines which parts of the content layer are visible and which are hidden.

Let’s learn how to create a text masking effect in Figma.

How to create a text mask

Masking is an excellent feature for creating a wide variety of text fills. You can use gradients, images, patterns or any custom fills to spice up your texts.

Here is a step-by-step tutorial to create a text mask –

1. Create a new Figma file

Go to the Figma icon on the top right > File > New design file.

2. Create a frame

Click the frame icon in the toolbox. You can also use the keyboard shortcut ‘F’.

Choose a desired size. I selected the Twitter header frame.

Frame created

3. Add your text layer

Pick the text tool from the toolbar. Click anywhere on the frame to type your text. You can adjust the size and style to your liking.

I chose the font “Font Awesome 5 Brands”, it adds the Figma logo in place of the word! I also increased the stroke to 5, to give it a little bit of weight.

Type your text in the frame

4. Add the Content layer

Now insert the image that you want to use as a mask. From the Rectangle tool dropdown, select ‘Place image/video'.

Browse for your desired image and add it to the frame.

You might have to resize your image a bit to fit into the frame. To do this, simply select your image layer and type in your desired height and width in the properties panel on the right. You can also resize by dragging the corners of your image.

I used this free image from Pexels.

Add your content layer image

Make sure you place the image on top of the text since it will be the content layer for your text mask.

5. Convert your text to a mask

Select the text layer in the Layers panel on the left. Right-click and select ‘Use as mask’.

masked text

Tada! You now have a beautiful text mask layer! You can move or resize the text layer or image layer. See what looks best.

There are a multitude of different ways this simple technique could be used to create compelling text designs in your User Interfaces.

  • Clipping images or videos to text - you can use any images or videos and use text as a mask to display them inside the text.

Stratego branding

  • Creative text overlays - try playing with colors, gradients, filters, and patterns.

  • Interactive elements - you can add text masking effects to create cool interactive elements that enhance the user experience. For example, use text masking to create a button that reveals an image or video when the user hovers over it.

  • Nested text masks- You can nest masks or content layers to creatively elevate your text elements. Here's an example -

nest text masks

See? The possibilities are endless. Get your creative juices flowing with these inspirations. Don't forget to experiment and practice. Once you get the hang of it, you will be able to create stunning text masks in no time! So go on and get designing :)

Top comments (0)