After Effects Blink Expression - What It Does & How To Use It

When you're working in After Effects, there are times when you want an element to blink or flicker without the hassle of setting multiple opacity keyframes. This is where the blink expression comes into play. It's a powerful tool that can save you time and offer flexibility in your animations.

October 29, 2023
After Effects Blink Expression - What It Does & How To Use It
"It's Like Video Editing On Steroids!"
- Sebastian Navarro, FreeVisuals Editor
Endorsed by Adobe, Motion Array is the ULTIMATE tool for creating high-quality videos! Browse 15M+ assets for Premiere Pro, After Effects, FCPX & DaVinci!

Blink Expression For Adobe After Effects

Blink Expression for After Effects

Prime Frame Blink Expression

t = framesToTime(time, thisComp.frameDuration) + (thisLayer.index * 12345); function isPrime(value) { for(var i = 2; i < value; i++) { if(value % i === 0) { return 100; } } return 0; } isPrime(t);

What does the Blink Expression do?

The blink expression in After Effects is used to make an element blink or flicker on and off. It's a more efficient method than manually setting a series of opacity keyframes, especially if you need to make adjustments later on. The expression can be applied to the opacity property of a layer, and it will control when the layer is visible (100% opacity) and when it's invisible (0% opacity).

How to use the Blink Expression

  1. Locate the Opacity Property: In your After Effects timeline, select the layer you want to apply the blink expression to. Press "T" on your keyboard, and this will bring up the Opacity property for that layer.
  2. Alt + Click: Hold down the "Alt" key (or "Option" key on Mac) and click on the stopwatch icon next to the Opacity property. This action will open up the expression editor.
  3. Enter the Expression: In the expression editor, you can type in or paste the blink expression. There are various ways to write this expression, but the core idea remains the same: to toggle the opacity between 100% and 0% based on specific conditions or timings.
  4. Fine-tune as Needed: Once the expression is applied, you can adjust parameters or conditions to get the desired blink frequency and pattern.

For instance, one method shared on Reddit involves using a mathematical function to check if the current frame is prime. If it is, the opacity is set to 0, and if it isn't, the opacity is set to 100. This method results in a fairly frequent flickering effect, which might be suitable for glitchy or digital effects.

Why is this useful?

The beauty of using expressions in After Effects, like the blink expression, is that it gives you a lot of control without cluttering your timeline with keyframes. If you've set everything up correctly, you'll have all the options and avenues you'd ever want to achieve the right look. It's during this phase that you can make the majority of your creative decisions, such as timing, frequency, and even the intensity of the blink.