packages/docs/docs/5-0-migration.mdx
:::note Remotion 5.0 is not yet released. This is an incomplete list of breaking changes that are planned for the release. :::
See the changelog to find the latest version.
Upgrade remotion and all packages starting with @remotion to the latest version, e.g. 5.0.0:
- "remotion": "4.0.141"
- "@remotion/bundler": "4.0.141"
- "@remotion/eslint-config": "4.0.141"
- "@remotion/eslint-plugin": "4.0.141"
- "@remotion/cli": "4.0.141"
- "@remotion/renderer": "4.0.141"
+ "remotion": "5.0.0"
+ "@remotion/bundler": "5.0.0"
+ "@remotion/eslint-config": "5.0.0"
+ "@remotion/eslint-plugin": "5.0.0"
+ "@remotion/cli": "5.0.0"
+ "@remotion/renderer": "5.0.0"
Run npm i , yarn, pnpm i or bun i respectively afterwards.
The following packages stop receiving releases after the 4.x line:
@remotion/light-leaks with lightLeak() from @remotion/effects.@remotion/starburst with starburst() from @remotion/effects.@remotion/media-parser with Mediabunny.@remotion/webcodecs with Mediabunny.Required action: Migrate usages and remove these packages from your dependencies before upgrading. Existing 4.x versions remain available, but no 5.x versions will be published.
The minimum Node version is now <MinNodeVersion />. The minimum Bun version is <MinBunVersion />.
If you use @remotion/eslint-config, the minimum ESLint version is now <MinEslintVersion />.
In Remotion 4.0, the default OpenGL renderer was null, which would not enable WebGL or WebGPU.
In Remotion 5.0, the default is angle with automatic fallback to swangle.
Lambda and Cloud Run continue to use swangle by default, because they have no GPU.
Required action: If you used --gl=angle before, you can now remove it.
selectComposition() and getCompositions() now require inputPropsinputProps is now required in selectComposition() and getCompositions().
A common footgun was the render was not working as intended because the input props were not passed.
Required action: Pass an empty object {} if you don't have any input props.
bundle() and getCompositions() now take an options objectThe legacy positional signatures of bundle() and getCompositions() have been removed.
The return value of bundle() remains the output directory as a string.
Required action: Move positional arguments into an options object:
- bundle(entryPoint, onProgress, options)
+ bundle({entryPoint, onProgress, ...options})
- getCompositions(serveUrl, options)
+ getCompositions({serveUrl, ...options})
visualizeAudio() yields different resultoptimizeFor: "speed" is now the default. This will yield slightly different results.
Required action: Review the visualization of your audio. If unsatisfactory, revert to the old behavior by setting optimizeFor: "accuracy".
layout="none" anymoreHaving a TransitionSeries with layout="none" is not supported anymore.
It never made sense to have this prop as transitioned elements need to be positioned absolutely.
Required action: Remove the layout prop.
measureSpring() does not accept from and to options anymoreThe values passed in there did not influence the calculation at all. Therefore we removed those options.
Required action: Remove the from and to options from your code.
null beyond the end of a pathgetPointAtLength() and getTangentAtLength() now return null if the requested length is greater than the return value of getLength().
Previously, they returned the point or tangent at the end of the path.
Required action: Handle the null return value or ensure that the requested length does not exceed the path length.
overwrite is now true by default in renderMediaOnLambda()The default value of overwrite in renderMediaOnLambda() has changed from false to true. This skips a check that the file already exists in the S3 bucket, which makes the render start faster.
Required action: Set overwrite: false if an existing file should still cause an error.
openBrowser() now takes a logLevel instead of shouldDumpIoThe shouldDumpIo option has been be removed in 5.0.
Use logLevel: "verbose" instead.
getVideoMetadata() has been removed from @remotion/rendererUse Mediabunny to get video metadata instead.
Required action: Replace calls to getVideoMetadata() from @remotion/renderer with getting metadata using Mediabunny.
diskSizeInMb is now 10240 by defaultFor Remotion Lambda, the default disk size is now 10240 MB.
This will add a miniscule cost to your renders technically, but will lead to more reliable and faster renders, since Chrome is less likely to run out of disk cache.
Required actions:
diskSizeInMb: 2048, explicitly.disk2048mb, unhardcode it and use speculateFunctionName() to get the correct name.@remotion/lambda/clientrenderMediaOnLambda(), getRenderProgress(), renderStillOnLambda(), presignUrl(), getSites() have been removed from @remotion/lambda.
They are now available in @remotion/lambda/client.
The default maxInstances for new Cloud Run services has been reduced from 100 to 5.
On some GCP accounts, the previous default exceeded the available Cloud Run quota and caused deployments to fail with an Invalid value specified for cpu error.
Required action: If you want to keep the old scaling limit, set maxInstances: 100 when using deployService(), or pass --maxInstances=100 to the Cloud Run CLI.
bt709 is now the default color spaceThe default colorSpace is now "bt709" instead of "default" (which was equivalent to "bt601").
The "default" option has been removed.
Required action: If you want to keep the old behavior, set colorSpace: "bt601" explicitly.
@remotion/google-fonts requires specifying weights and subsetsWhen using loadFonts() from @remotion/google-fonts, you must now specify which font weights and subsets you want to load. Loading all weights and subsets by default is no longer supported as it can lead to timeouts.
Required action: Explicitly specify the weights and subsets you need:
import {loadFont} from '@remotion/google-fonts/Roboto';
loadFont('normal', {
weights: ['400', '700'],
subsets: ['latin'],
});
validateFontIsLoaded is now true by default in @remotion/layout-utilsmeasureText(), fitText(), fillTextBox(), and fitTextOnNLines() now default validateFontIsLoaded to true.
Required action: Ensure custom fonts are loaded before calling these APIs, or pass validateFontIsLoaded: false explicitly to keep the previous behavior. See layout utils best practices.
<Sequence>, <Series.Sequence> and <TransitionSeries.Sequence> components now automatically premount for 1 second (fps frames) before they appear.
This prevents black frames that were commonly seen when a <Sequence> containing heavy content (e.g. videos, images) appeared.
Required action: If you don't want this behavior for a specific Sequence, opt out by passing premountFor={0}.
<Video> and <Audio> from @remotion/media have paused playback while loading by default since they were introduced.
<Html5Video>, <OffthreadVideo>, and <Html5Audio> now set pauseWhenBuffering to true by default.
`` now sets pauseWhenLoading to true by default.
This prevents the Player from continuing while media or images are still loading.
Required action: If you want to keep the old behavior, set pauseWhenBuffering={false} on video and audio components and pauseWhenLoading={false} on `` explicitly.
Remotion 5.0 has an updated license. View the license here or compare the changes.
There are two effective changes in this license: