Skip to content
The Admin Bar
  • Get Involved
    • Facebook Group
    • Barfly Community
    • TABLE Mastermind
  • Learn
    • 2026 Survey
    • Articles
    • Events
    • Newsletter
    • YouTube
    • WordPress Professionals Survey
    • SEO Weekly
    • Security Weekly
    • Accessibility Weekly
  • Products
    • The Paid Discovery Class
    • Website Owner’s Manual
    • Agency Copilot
    • Website Pricing Calculator
    • Agency Airtable Pack
    • Prospect Pipeline Challenge
    • Easy-Peasy Proposal
    • TAB Swag
  • About
  • Free Stuff

How to Create a Scroll-Reveal Effect with CSS in GeneratePress and GenerateBlocks

Recreate Google DeepMind’s scroll-reveal effect in GeneratePress & GenerateBlocks with this simple CSS trick—no JavaScript needed!

Kyle Van Deusen

Published:

January 23, 2025

Filed Under:

WordPress

Kyle Van Deusen

The Admin Bar

After spending 15 years as a graphic designer and earning a business degree, I launched my agency, OGAL Web Design, in 2017. A year later, after finding the amazing community around WordPress, I co-found The Admin Bar, which has grown to become the #1 community for WordPress professionals. I'm a husband and proud father of three, and a resident of the Commonwealth of Virginia.

Reveal

This content contains affiliate links. View our affiliate disclaimer.

Recently, I stumbled across Google DeepMind’s Gemini-era landing page, and let me tell you—it’s packed with some seriously cool design elements. But one feature in particular caught my eye: a scroll-reveal effect that feels like peeling back a curtain as you scroll down the page.

Now, we’ve all seen scroll-based effects before—images that start small and scale up as you scroll, for example. But this was different. The image stayed the same size, and instead, a mask around it was revealed as you scrolled. Naturally, I had to figure out how to recreate this effect using GeneratePress and GenerateBlocks. Spoiler alert: it’s surprisingly simple, and I’ll walk you through it step by step.

Youtube video

Setting Up the Layout

For this demo, I created a basic page layout with three sections:

  1. Top Section: A minimum height of 100% viewport height to give us room to scroll.
  2. Middle Section: This is where the magic happens. It contains a wrapper, an inner container, and the image we’ll apply the reveal effect to.
  3. Bottom Section: Another 100% viewport height section for additional scrolling space.

The middle section is where we’ll focus our efforts. While I’m using an image for this example, you can apply the effect to any element on your site. Just don’t go overboard—subtlety is key here.

Adding the Class for the Effect

To start, I added a custom class to the image element: owd-reveal. This class will be the target for our CSS magic. Once the class is set, I updated the page and jumped into the WordPress Customizer to write the CSS.

Writing the CSS

Here’s the CSS that powers the scroll-reveal effect:

css.owd-reveal {
  animation: owd-reveal linear forwards;
  animation-timeline: view();
  animation-range: entry;
}

@keyframes owd-reveal {
  0% {
    clip-path: inset(25%);
  }
  100% {
    clip-path: inset(0%);
  }
}

Breaking It Down:

  1. Animation Name: The animation is called owd-reveal, and it runs linearly without repeating.
  2. Animation Timeline: The view() function ties the animation to the viewport, so it triggers as the element enters the screen.
  3. Animation Range: entry ensures the animation runs as the element enters the viewport.
  4. Keyframes: The clip-path property creates the reveal effect. At 0%, the image is masked by an inset of 25%. At 100%, the mask is removed, revealing the full image.

Enhancing the Effect

Adding a Border Radius

One issue with the clip-path approach is that it overrides any border radius applied directly to the image. To fix this, I added a round value to the clip-path at 100%:

css@keyframes owd-reveal {
  0% {
    clip-path: inset(25%);
  }
  100% {
    clip-path: inset(0%) round 16px;
  }
}

This ensures the border radius grows subtly as the image is revealed, adding a nice touch to the animation.

Using Custom Properties

To make the CSS more manageable, I introduced a custom property for the border radius:

css:root {
  --radius: 16px;
}

@keyframes owd-reveal {
  0% {
    clip-path: inset(25%);
  }
  100% {
    clip-path: inset(0%) round var(--radius);
  }
}

Now, if I want to change the border radius, I only need to update the --radius value.

Fine-Tuning the Reveal

The clip-path inset percentage controls how much of the image is initially hidden. Here’s how different values affect the animation:

  • 50%: The image is almost completely hidden, making the reveal happen faster.
  • 10%: The effect is too subtle and barely noticeable.
  • 25%: A balanced choice that ensures the reveal is visible without being overwhelming.

Feel free to experiment with this value based on your design needs.

Accessibility Considerations

Animations are fun, but they shouldn’t come at the expense of accessibility. To respect users who prefer reduced motion, you can wrap the animation in a prefers-reduced-motion media query:

css@media (prefers-reduced-motion: no-preference) {
  .owd-reveal {
    animation: owd-reveal linear forwards;
    animation-timeline: view();
    animation-range: entry;
  }
}

This ensures the effect only runs for users who haven’t opted out of motion-based animations.

Final Thoughts

This scroll-reveal effect is a great way to add subtle interactivity to your site without overwhelming visitors. It’s perfect for landing pages or sections where you want to draw attention to specific elements. Just remember: less is more. Overusing animations can quickly turn a sleek design into a chaotic mess.

I first noticed this effect on Google’s landing page, and it immediately sparked ideas for my own projects. With just a few lines of CSS, you can recreate it and customize it to fit your needs. Whether you’re using GeneratePress, GenerateBlocks, or another stack, this technique is a great addition to your toolkit.

So, what do you think? Ready to give this a try on your next project?

Kyle Van Deusen

The Admin Bar

After spending 15 years as a graphic designer and earning a business degree, I launched my agency, OGAL Web Design, in 2017. A year later, after finding the amazing community around WordPress, I co-found The Admin Bar, which has grown to become the #1 community for WordPress professionals. I'm a husband and proud father of three, and a resident of the Commonwealth of Virginia.

Come Join Us!

Join the #1 WordPress Community and dive into conversations covering every aspect of running an agency!

Join Group

Kyle Van Deusen

Community Manager

Latest Events

February, 26th, 2026

Code Snippets Are Slowing Down Your Website

Why Perfmatters Built a Performance-First Snippet Manager

January 20th, 2026

Revolutionizing How Small Agencies Grow Their Business Efficiently

September 16, 2025

Termageddon 2.0

Better Tools, Smoother Workflows, Happier Clients
Tpdc onblue

Learn a proven discovery framework to transform casual leads into high-paying clients.

View the Course
The Friday Chaser

Wash down the week with the best of The Admin Bar! News, tips, and the best conversations delivered straight to your inbox every Friday!

Subscribe Today

More Articles

A smiling man with glasses and a patterned shirt, member profile on The Admin Bar website.
May 20, 2026

Member Spotlight: Mayank Majeji

Mayank Majeji’s story feels a lot like the way many of us got into this industry: …

A woman working on a laptop with a large pill bottle labeled "Free Privacy Policy Template" on the t.
May 19, 2026

Why Privacy Policy Templates Can Backfire for Agencies and Website Owners

Free Privacy Policy templates seem harmless until a client gets sued. Here’s what every web agency needs to know before using one.

Close-up of a "Sold" sign hanging on a wooden frame in front of a house.
May 19, 2026

The Industry Web Agencies Should Be Copying

Real estate agents have spent 100 years mastering referral marketing. Here’s how web agencies can borrow their best moves.

2025phone

Join the #1 WordPress Community

The Admin Bar community is at the heart of what we do. Join in on the daily conversation and get involved.

Request Membership
The Admin Bar logo.

Explore

Community

Events

Articles

Products

Newsletter

Agency Report Card

Care Plan Toolkit

Noted!

Barfly Login

Policies

Privacy Policy

Terms of Service

Affiliate Agreement

Affiliate Disclaimer

Accessibility Statement

Privacy Settings

Misc.

Advertise

Login

Contact

Hosted with Rocket.net

© 2017-2026 The Admin Bar (a Division of OGAL Web Design) — All Rights Reserved

The Admin Bar logo.
  • Get Involved
    • Facebook Group
    • Barfly Community
    • TABLE Mastermind
  • Learn
    • 2026 Survey
    • Articles
    • Events
    • Newsletter
    • YouTube
    • WordPress Professionals Survey
    • SEO Weekly
    • Security Weekly
    • Accessibility Weekly
  • Products
    • The Paid Discovery Class
    • Website Owner’s Manual
    • Agency Copilot
    • Website Pricing Calculator
    • Agency Airtable Pack
    • Prospect Pipeline Challenge
    • Easy-Peasy Proposal
    • TAB Swag
  • About
  • Free Stuff
YouTube Facebook
Sell More Care Plans