Skip to main content

restartStudio()v4.0.162

Restarts the Remotion Studio server.

MyComp.tsx
import { restartStudio } from "@remotion/studio"; import { useCallback } from "react"; const MyComp: React.FC = () => { const onClick = useCallback(async () => { try { await restartStudio(); console.log("Studio will restart now"); } catch (err) { console.error(err); } }, []); return ( <button type="button" onClick={onClick}> Hello World </button> ); };

Requirements​

This function is only available in a writable Studio with a running server. It throws outside Studio, in remotion.new, or in a read-only Studio.

Return value​

Returns a promise that resolves to an empty object when the server acknowledges the restart request. Studio launches a fresh CLI process on the same port, so package upgrades take effect after restarting. The browser temporarily disconnects while Studio restarts.

Compatibility​

BrowsersEnvironments
Chrome
Firefox
Safari
Local Studio

See also​