How can I use Webflow divs to create multiple clipping-masks that reveal parts of an image?

Published on
September 22, 2023

To create multiple clipping masks using Webflow divs, follow these steps:

  1. Prepare the image: Make sure you have the image you want to use for the clipping mask ready. You can upload it to your Webflow project or use an existing image URL.

  2. Add a new div: In the Webflow Designer, select the element where you want to add the clipping mask and add a new div by clicking the '+' button or using the shortcut 'Ctrl + D'. Position and resize the div to the desired area where you want to reveal part of the image.

  3. Set the div as a mask: With the newly added div selected, go to the Style panel on the right-hand side and locate the 'Display' property. Change it from the default 'Block' to 'Mask'.

  4. Configure the mask style: In the same Style panel, find the 'Mask Image' property. You can either enter the image URL or select an uploaded image from your project's assets. Adjust the 'Mask Position' and 'Mask Size' properties to control how the image is positioned and scaled within the div.

  5. Repeat steps 2-4: If you want to create additional clipping masks, repeat steps 2-4 for each div you want to add to your design. You can play with different shapes, sizes, and positions to create unique mask effects.

  6. Arrange the stacking order: If your divs overlap, make sure to arrange them in the desired order using the 'Bring Forward' or 'Send Backward' buttons in the Webflow Designer. This will ensure that the masking effect appears as intended.

  7. Preview and refine: Lastly, preview your design and make any necessary adjustments to the div sizes, positions, or mask properties until you achieve the desired effect. You can also experiment with additional styling options like background colors or gradients to enhance your design.

By using Webflow's built-in masking feature and multiple divs, you can create intricate clipping mask effects to reveal specific parts of an image. Enjoy the creative possibilities that this technique offers!

Example code:

<div class="mask-div"></div>
.mask-div {  display: mask;  mask-image: url('image.jpg');  mask-position: center;  mask-size: cover;}

Additional Questions:

  1. How do I create a clipping mask on a Webflow div?
  2. Can I use multiple images as clipping masks in Webflow?
  3. How can I add custom shapes to my image clipping masks in Webflow?