Skip to main content

Font loading errors

Render timeout when loading Google Fonts

When using @remotion/google-fonts, you may encounter timeout errors like:

- A delayRender() "Fetching Inter font {"style":"normal","weight":"100","subset":"cyrillic-ext"}" was called but not cleared after 58000ms.

Problem

In Remotion 4.0, calling loadFont() without arguments loads all available font weights and character subsets, which can cause timeouts. From v5.0, you must pass non-empty weights and subsets arrays — otherwise loadFont() throws.

Solution

Only load the specific font weights and character subsets that your project needs:

import {loadFont} from '@remotion/google-fonts/Inter';

// ❌ Avoid: Loading all weights and subsets
loadFont();

// ✅ Recommended: Load only required weights and subsets
loadFont('normal', {
  subsets: ['latin'],
  weights: ['400', '700'], // Only load regular (400) and bold (700)
});

If your project uses multiple fonts, centralize font loading in one module and wait until all fonts are loaded before rendering: