Skip to article

Motion Studio

Edit Motion animations directly on your website with a visual editor and fast animation editor AI. Then apply changes to source with your existing code agent.

Motion Studio puts a timeline directly on your website. Select an animation, edit visually with AI, apply direct to source code.

Edit and preview animations without leaving your website. A visual animation editor combined with a fast animation editing agent.

0.00.51.01.5
h1
.description
buttons
0.00 / 1.52s

Motion Studio is free to install and edit animations visually. Apply to code needs Motion+. The Ultramotion editing agent needs Motion Cloud, and every signed-in account gets 5 free Ultramotion prompts each month.

Supported environments

Studio runs in your local development environment. The bundler integration and the animation code that reaches the browser determine what Studio can edit.

EnvironmentSupport
Next.js with TurbopackSupported with withMotionStudio and the companion Studio server.
Next.js with WebpackSupported with the same Next.js wrapper and companion server.
ViteSupported with the motionStudio() plugin.
WebpackSupported with the development-only Studio loader and companion server.
Nuxt with ViteSupported with motionStudio({ serverUrl }) and the companion Studio server. Use explicit Motion imports in Vue components.
AstroSupported with the same Vite plugin and companion server for imported client scripts and hydrated React or Vue components.

Nuxt and Astro were verified with Nuxt 4.5.2, Astro 7.3.3 and Node.js 22.19.0. Checks cover animation discovery, preview, Apply, hot reload and production builds without Studio code. Your framework may need a newer Node.js version than Studio's minimum.

React Server Component boundaries

In the Next.js App Router, keep animations you want to edit in client modules. Studio preserves the "use client" directive and does not add it to Server Components. The panel starts only in the browser.

A Server Component can render an animated Client Component. Put "use client" at the top of the client entry file, before its imports:

"use client"

import { motion } from "motion/react"

export function AnimatedCard() {
  return <motion.div animate={{ opacity: 1 }} initial={{ opacity: 0 }} />
}

Keep server data fetching in the Server Component and pass serialisable props to the Client Component. Studio discovers animation code that runs in the browser. Animation definitions that run only on the server are outside that discovery path. See the Next.js guide to Server and Client Components for boundary rules.

Nuxt and Astro

Nuxt and Astro control their own HTML output. Set serverUrl on the Vite plugin so instrumented client modules can load the panel from the companion server. This setup does not depend on Vite's HTML hook.

In Nuxt, import the Motion APIs you use from motion-v in each Vue file. Studio needs these imports to discover the animation source. Nuxt auto-imports alone are not enough.

In Astro, put JavaScript animations in a .js or .ts file imported by a client script. React and Vue components need a client:* directive. Studio waits for an island to hydrate before starting a component preview. Server-only components, Astro frontmatter and animation definitions written directly inside .astro script blocks are not supported.

Install

Motion Studio requires Motion 13.3.0 or later and Node.js 22.13 or later, or the newer Node.js version your framework requires. Studio runs in your local Vite, Next.js, Nuxt, Astro or Webpack development environment.

Copy this prompt into your agent to install Motion Studio.

Show manual setup

Install the package

Run this command from your app's directory:

npm install -D motion-studio

Use your project's package manager if it uses Yarn, pnpm or Bun. Then follow the steps for your framework. Keep your existing configuration and add the Studio integration to it.

Vite

Add motionStudio() to the plugins array in vite.config.ts, before your React or Vue plugin:

import { motionStudio } from "motion-studio"
import { defineConfig } from "vite"
import react from "@vitejs/plugin-react"

export default defineConfig({
  plugins: [motionStudio(), react()],
})

For Vue, keep your existing vue() plugin in place of react(). For plain JavaScript, use plugins: [motionStudio()].

Run your normal development command. Vite starts the Studio server for you. The plugin only runs in development.

Next.js

Wrap your existing config with withMotionStudio in next.config.mjs or next.config.ts:

import { withMotionStudio } from "motion-studio/next"

const nextConfig = {
  // Keep your existing Next.js options here.
}

export default withMotionStudio(nextConfig)

The wrapper supports both Turbopack and Webpack. It enables Studio during next dev and leaves production builds unchanged.

Run your normal development command. In a second terminal, start the Studio server from the same app directory:

npx motion-studio serve

Keep both commands running. Studio uses http://localhost:5200 by default. If you change the server port, pass the matching serverUrl as the second argument to withMotionStudio.

Nuxt

Add the plugin to vite.plugins in nuxt.config.ts. Keep your existing Nuxt options and plugins:

import { motionStudio } from "motion-studio"

export default defineNuxtConfig({
  vite: {
    plugins: [motionStudio({ serverUrl: "http://localhost:5200" })],
  },
})

Run your normal Nuxt development command. In a second terminal, run npx motion-studio serve from the same app directory. Keep both commands running. This integration supports Nuxt's Vite builder.

Use explicit imports in your Vue components:

<script setup>
import { motion } from "motion-v"
</script>

<template>
  <motion.div :animate="{ opacity: 1 }" />
</template>

Astro

Add the plugin to vite.plugins in astro.config.mjs or astro.config.ts. Keep your existing integrations, including any React or Vue integration:

import { defineConfig } from "astro/config"
import { motionStudio } from "motion-studio"

export default defineConfig({
  vite: {
    plugins: [motionStudio({ serverUrl: "http://localhost:5200" })],
  },
})

Run your normal Astro development command. In a second terminal, run npx motion-studio serve from the same app directory. Keep both commands running.

For JavaScript animations, create a client module such as src/scripts/animate.ts:

import { animate } from "motion"

animate(".card", { opacity: [0, 1] }, { duration: 0.4 })

Import it from the page's client script. For a page in src/pages/, this can be:

<div class="card">Hello</div>
<script>
  import "../scripts/animate"
</script>

Keep the animation definition in the imported file so Studio can edit it. For React or Vue animations, hydrate the component, for example with <AnimatedCard client:load />. A component rendered only on the server cannot appear in the timeline.

For Nuxt and Astro, the plugin runs only during development. Production builds exclude Studio. If you change the companion server port, set the same port in serverUrl.

Webpack

Add a development-only pre-loader to your existing module.rules in webpack.config.cjs. Keep your other rules and options:

module.exports = (_env, argv) => ({
  module: {
    rules: [
      ...(argv.mode === "development" ? [{
        test: /\.(?:[cm]?[jt]s|[jt]sx)$/,
        exclude: /node_modules/,
        enforce: "pre",
        use: [{
          loader: require.resolve("motion-studio/loader"),
          options: { boot: { serverUrl: "http://localhost:5200" } },
        }],
      }] : []),
      // Keep your existing rules here.
    ],
  },
})