HyperFrames vs Motion Canvas for Code Animation
Compare HyperFrames and Motion Canvas for HTML video and TypeScript vector animation, with voice-over timing, rendering, licensing, and a small example.
Updated Dec 4, 2026
Choose HyperFrames when the proposed video already resembles a web page, with styled text, footage, and UI components that belong in the DOM. Choose Motion Canvas when the scene is an animated diagram and its author wants TypeScript generators, a canvas scene graph, and editor-adjustable timing around a voice-over. Both are open source. Their different layout and timing models have more impact on day-to-day work than the choice of video export format. HyperFrames repository · Motion Canvas documentation
Comparison
| Dimension | HyperFrames | Motion Canvas |
|---|---|---|
| Authoring model | Timed HTML compositions with DOM layers | Canvas scene graph, signals, and generator-driven animation |
| Language | HTML, CSS, JavaScript, often GSAP | TypeScript, commonly with JSX for scene nodes |
| Rendering | Chrome frame capture and FFmpeg encoding | Editor export to images or video through the FFmpeg exporter |
| Licensing | Apache-2.0 | MIT |
| AI-agent support | Official skills and plugins for HTML authoring, validation, and rendering | TypeScript APIs and docs an agent can work from, with editor playback for review |
| Cloud and distributed rendering | CLI-supported Lambda, Cloud Run, and HeyGen cloud paths | The documented export flow runs through the editor and exporters. Remote automation needs a workflow around those tools |
| Ecosystem maturity | Registry of HTML components and official agent skills | Focused documentation for scenes, animation flow, plugins, and exporters |
| Learning curve | CSS, composition attributes, and seekable timelines | Scene coordinates, reactive signals, generators, and editor time events |
| Cost | No license fee for the open-source CLI. Optional hosted services and self-managed compute can add cost | No framework license fee. Budget for any compute and other services you use |
See the Motion Canvas license, rendering overview, and FFmpeg exporter for the project’s export model.
How the timing differs
A HyperFrames scene can reuse the layout conventions of a product site. CSS places the items, while clip timing and the animation timeline make them visible and moving at the right moment. This works well for slides made out of web components, a title over footage, or a launch clip with an edited screen capture. A render worker must be able to load the assets used by that HTML.
A Motion Canvas scene describes nodes such as rectangles and lines, and a generator yields animation tasks in sequence. Signals let the scene express relationships between properties. If two boxes move, a connecting line can follow the positions declared by the scene. For a narrated explainer, the editor can adjust time events that code waits for, which is useful when a voice recording changes length. Motion Canvas tweening · Motion Canvas time events
Example scaling a square
In HyperFrames, the square is a positioned element in a 640 × 360 composition. Save the example as index.html and use npx hyperframes render --output square.mp4. The square doubles in size over the first second and holds for the second.
<!doctype html>
<html lang="en">
<meta charset="utf-8">
<script src="https://cdn.jsdelivr.net/npm/[email protected]/dist/gsap.min.js"></script>
<style>
body { margin: 0; background: #121827; }
#square { position: absolute; left: 300px; top: 160px;
width: 40px; height: 40px; background: #fbbf24; }
</style>
<div data-composition-id="square" data-width="640" data-height="360"
data-start="0" data-duration="2">
<div id="square" class="clip" data-start="0" data-duration="2" data-track-index="0"></div>
</div>
<script>
window.__timelines = window.__timelines || {};
window.__timelines.square = gsap.timeline({ paused: true })
.to("#square", { scale: 2, duration: 1, ease: "none" }, 0);
</script>
</html>
In a Motion Canvas project, add this scene and register it in the project. Set the project resolution to 640 × 360, then preview or export from the editor. Here the square is a node at the center of the view, and the generator makes the hold explicit. Motion Canvas quickstart
import {makeScene2D, Rect} from "@motion-canvas/2d";
import {createRef, linear, waitFor} from "@motion-canvas/core";
export default makeScene2D(function* (view) {
const square = createRef<Rect>();
view.fill("#121827");
view.add(<Rect ref={square} width={40} height={40} fill="#fbbf24" />);
yield* square().scale(2, 1, linear);
yield* waitFor(1);
});
Choose by what you need to revise
Choose HyperFrames if revisions mostly change footage, labels, layout, or repeatable visual treatments across different projects. Use the browser inspector and a short export to check line wrapping and letterboxing. Choose Motion Canvas if revisions mainly change the sequence of a diagram, the layout of its dependent nodes, or the narration cue points. Review the timing with the real voice track, especially around events that trigger the next animation.
Move timing and assets deliberately
When bringing a Motion Canvas clip into HyperFrames, export it at the target frame rate and import it as footage if the vector animation will stay in Motion Canvas. For an editable port, write down the important cue times, convert canvas coordinates to CSS pixels or SVG coordinates, and translate generator steps into a timeline. A reactive connector between nodes needs equivalent behavior in its new representation. Preserve voice-over offsets when comparing the original with the port.
For movement in the other direction, rebuild only the graphics that benefit from scene nodes. Test fonts and line wrapping against an original export. The HyperFrames remotion-to-hyperframes skill documents a different source framework, but its timing and font checks are useful reference points during a manual port. HyperFrames migration skill
For equation-heavy motion graphics, see HyperFrames vs Manim. For a React-first rendering stack, see HyperFrames vs Remotion.