--- name: assets description: Importing images, videos, audio, and fonts into Remotion metadata: tags: assets, staticFile, images, fonts, public --- # Importing assets in Remotion ## The public folder Place assets in the `public/` folder at your project root. ## Using staticFile() You MUST use `staticFile()` to reference files from the `public/` folder: ```tsx import { Img, staticFile } from "remotion"; export const MyComposition = () => { return ; }; ``` The function returns an encoded URL that works correctly when deploying to subdirectories. ## Using with components **Images:** ```tsx import { Img, staticFile } from "remotion"; ; ``` **Videos:** ```tsx import { Video } from "@remotion/media"; import { staticFile } from "remotion";