After Effects Expressions with AI: A Beginner’s Guide

Quick answer: After Effects expressions are short pieces of JavaScript you attach to a property, like Position or Opacity, to animate it automatically. In 2026 you can get AI to write them for you: ChatGPT and Claude can turn a plain-English request into a working expression, and Adobe has added an AI Assistant to After Effects (beta) that can write, explain and fix expressions right inside the app. You still need the basics, so you can tell when the AI gets it wrong.

What an expression is, in one minute

Keyframes tell After Effects exactly what happens and when. Expressions tell it how a value should behave, so it keeps working when you change timing or duplicate layers. To add one, hold Alt (Windows) or Option (Mac) and click the stopwatch next to any property, then type or paste the expression.

6 expressions every beginner should know

  • Wiggle (random motion): wiggle(3, 25) moves the value 3 times a second by up to 25 units. Great for camera shake or floating objects.

  • Loop (repeat your keyframes): loopOut("cycle") repeats your animation forever. Use loopOut("pingpong") to play it back and forth.

  • Time (constant motion): time * 90 on Rotation spins a layer 90 degrees per second, with no keyframes.

  • Linear (map one range to another): linear(time, 0, 2, 0, 100) on Opacity fades a layer in over the first 2 seconds.

  • Slider control (make it adjustable): add a Slider Control effect, then use wiggle(effect("Slider Control")("Slider"), 25) so anyone can change the speed without touching code.

  • Number counter (animated stats): on a text layer's Source Text, Math.round(linear(time, 0, 3, 0, 1000)) counts from 0 to 1,000 over 3 seconds.

How to get ChatGPT or Claude to write an expression that works

The quality of the answer depends on the quality of the request. Tell the AI five things:

  • The property: Position, Scale, Rotation, Opacity or Source Text.

  • The layer type: shape layer, text layer, null or 3D layer.

  • The behavior, in plain words: "bounce to a stop after the last keyframe".

  • Units and timing: pixels, degrees, seconds.

  • Controls you want: "use a slider for the amount".

Example prompt: "Write an After Effects expression for the Position property of a shape layer. After the last keyframe it should overshoot and settle with an elastic bounce. Add slider controls for amplitude and frequency, and comment each line."

Ask for comments in the code. They help you learn, and they make it easy to spot when something does not match what you asked for.

Using the new After Effects AI Assistant

Adobe's AI Assistant is available in After Effects (Beta). Open your project and choose Window > Assistant. Select the layer and property you want to work on, then type a request like "write an expression that loops this animation", "explain this expression" or "why is this expression throwing an error?". According to Adobe, it can write new expressions from plain language, read existing ones back in plain English, explain errors, and update expressions when you rename layers or effects.

Because it sees your actual project, it avoids one of the most common chatbot mistakes: referring to layers and effects by the wrong name.

When AI gets it wrong (and how to fix it)

  • Wrong number of dimensions. Position needs two values in 2D (three in 3D), Opacity needs one. If you see "expression result must be of dimension 2", tell the AI which property you are on.

  • Wrong layer or effect names. Expressions break if thisComp.layer("Logo") does not match your real layer name. Rename the layer or fix the text.

  • Made-up functions. Chatbots sometimes invent functions that do not exist in After Effects. If the error says something is not a function, ask the AI to use only built-in After Effects expression methods.

  • Legacy vs JavaScript engine. Modern projects use the JavaScript engine (Project Settings > Expressions). Old tutorials sometimes use legacy syntax.

The workflow we actually use at Pixel Pro

On client projects we design the look by hand first: style frames, timing and easing are where the craft is. Then we use AI for the repetitive parts: writing rig expressions with sliders, staggering dozens of layers, building counters and data-driven graphics, and debugging when something breaks. A task that used to mean an hour on a forum often takes a few minutes now. The result is the same quality, delivered faster.

After Effects expressions with AI: FAQ

Do I need to know JavaScript to use expressions?

No. Most everyday expressions are one line long. Knowing a handful of basics, like wiggle, loopOut and linear, is enough to read and adjust what AI writes for you.

Can ChatGPT write After Effects expressions?

Yes. ChatGPT and Claude both write working expressions when you describe the property, layer type and behavior clearly. Always test them, and ask for comments so you understand what each line does.

Is the After Effects AI Assistant free?

It is currently available in After Effects (Beta) for Creative Cloud subscribers. Check Adobe's help pages for the latest availability, because beta features change.

Will AI replace motion designers?

AI is replacing the busywork, not the designer. Clients still hire people for ideas, taste, timing and storytelling. Motion designers who use AI well simply deliver more in less time.

Where can I learn expressions properly?

Our Motion II course covers After Effects expressions, ChatGPT automation, Cinema 4D 3D text, green screen, tracking and rotoscoping. New to After Effects? Start with the beginner After Effects course.

Want to learn this step by step? See the Pixel Academy courses, or hire us for motion graphics instead.

Source for the AI Assistant features: Adobe Help Center, "After Effects AI Assistant overview" (updated November 2026).

Next
Next

How Much Does an Explainer Video Cost in 2026?