ExtendScript is Adobe's scripting language, based on JavaScript, built into After Effects. It lets you automate anything you can do manually in the application — and many things you cannot do manually at all.
This guide is for motion designers who want to understand what scripting can do and how to start.
What You Can Automate With ExtendScript
Layer operations — create, duplicate, delete, rename, reorder, parent, and group layers programmatically.
Property animation — read and write keyframe values. Add keyframes at specific times with specific values. Modify easing curves.
Effect application — apply any After Effects effect to any layer. Set effect parameters. Apply presets.
Composition management — create new compositions, change their settings, add layers from footage items.
File operations — read and write files, process data from external sources, export information about projects.
UI — create custom floating panels and dialog boxes using ScriptUI, After Effects' built-in UI framework.
Running Your First Script
The simplest way to run an ExtendScript is from the Scripts menu:
File → Scripts → Run Script File
This opens a file browser. Select a .jsx file and it runs immediately.
For scripts you use regularly, copy them to: Applications/Adobe After Effects [version]/Scripts/ScriptUI Panels/
After restarting After Effects, they appear under the Window menu and can be docked like any built-in panel.
Your First Script — Hello After Effects
Open the ExtendScript Toolkit (or any text editor), create a file called hello.jsx, and add:
alert("Hello from After Effects!");
Run it from File → Scripts → Run Script File. A dialog box appears with your message.
More useful: create a new composition:
var comp = app.project.items.addComp("My Comp", 1920, 1080, 1, 10, 25);
This creates a 1920×1080 composition, pixel aspect ratio 1, 10 seconds long, at 25fps.
The After Effects Object Model
Everything in an AE project is accessible through a hierarchy of objects:
app— the applicationapp.project— the current projectapp.project.items— all items in the project (compositions, footage, folders)app.project.activeItem— the currently active itemcomp.layers— all layers in a compositionlayer.property("ADBE Transform Group").property("ADBE Position")— a specific property on a layer
The key challenge in AE scripting is knowing the right property names. After Effects uses internal matchName identifiers that are always in English regardless of the application language — this is important for writing scripts that work across localised versions.
matchName vs UI Names
This is the most important concept for reliable scripting:
Bad practice:
layer.property("Position") // breaks in non-English AE
Good practice:
layer.property("ADBE Transform Group").property("ADBE Position") // works everywhere
Always use matchName references when accessing properties programmatically. The After Effects Scripting Guide from Adobe lists all matchNames.
Where to Go Next
The official resource is the After Effects Scripting Guide — comprehensive documentation of the full API.
For practical examples, looking at open-source scripts and reading through how they work is the fastest way to learn. The Dream Chaser scripts on Payhip — including the Liquid Glass Script and SaaS Panel Kit — are built on these same principles: matchName references, ScriptUI panels, and FFX presets embedded as base64 strings for easy distribution.
The barrier to writing useful scripts is lower than most motion designers expect. A script that saves 10 minutes per project pays for the time spent learning it on the fifth use.