remotion-dev/remotion · error · Error
This component must be inside a <Series /> component.
Error message
This component must be inside a <Series /> component.
What it means
Series-context hooks (useRequireToBeInsideSeries) read IsInsideSeriesContext, which <Series> sets to true for its descendants and which the <IsOutsideSeries> provider sets to false. If the context is false/absent, calling such a hook throws to enforce that these APIs only run within a <Series>.
Source
Thrown at packages/core/src/series/is-inside-series.tsx:28
{children}
</IsInsideSeriesContext.Provider>
);
};
export const IsNotInsideSeriesProvider: React.FC<{
readonly children: React.ReactNode;
}> = ({children}) => {
return (
<IsInsideSeriesContext.Provider value={false}>
{children}
</IsInsideSeriesContext.Provider>
);
};
export const useRequireToBeInsideSeries = () => {
const isInsideSeries = React.useContext(IsInsideSeriesContext);
if (!isInsideSeries) {
throw new Error('This component must be inside a <Series /> component.');
}
};
View on GitHub (pinned to 78fe4bb3fd)
Solutions
- Wrap the consuming component in a <Series>.
- Use the standalone (non-series) equivalent of the component/hook if one exists.
Example fix
// before
<SeriesChild />
// after
<Series>
<Series.Sequence durationInFrames={30}><SeriesChild/></Series.Sequence>
</Series> Defensive patterns
Strategy: type-guard
Validate before calling
// Structure-only guard: ensure the component is only rendered under <Series>. // React Context default is false, so misuse throws at render time by design.
Type guard
// No runtime type guard needed; the hook itself enforces via context. // Structural fix: only mount these components inside <Series>.
Prevention
- Always render Series-context components under <Series>.
- When refactoring, keep the <Series> wrapper around moved children.
- Use the standalone equivalent when not in a series.
When it happens
Trigger: Using a Series-context hook or Series-only component outside any <Series> ancestor; refactoring that removes the <Series> wrapper around a child that still expects it.
Common situations: Copy-pasting a Series child component into a non-series area; splitting a composition and forgetting to keep the <Series> parent.
Related errors
- The "offset" property of a <Series.Sequence /> must not be N
- The "offset" property of a <Series.Sequence /> must be finit
- The <Series /> component only accepts a list of <Series.Sequ
- The <Series /> component only accepts a list of <Series.Sequ
- The "durationInFrames" prop ${component} is missing.
AI-assisted analysis of remotion-dev/remotion@78fe4bb3fd (2026-08-12).
Data as JSON: /api/errors/fa7ee2bbdd02e347.
Report an issue: GitHub.