Skip to main content
Upload media once, then reuse it in content, pages, and AI chat. Files created by Fimo’s generation commands land in the same media library.

Upload and find files

The upload response includes the asset ID and URL. Store media fields as { source: 'local', url, alt } with that URL. Do not copy the asset’s ID, name, MIME type, width, or height into the field. Name the media field in populate before passing it to an image component:
For media inside blocks, name the top-level blocks field to populate every media value inside it. Generated clients accept the same field name, for example BlogPost.getBySlug('hello', { populate: ['cover'] as const }). Verify the returned intrinsic width and height, pass the whole value to <Image>, and check the optimized responsive srcset at desktop and mobile widths. With optimization enabled on an eligible Fimo URL, sizes set, and no custom srcSet, generated width candidates stop at the intrinsic width. Your component props and CSS still choose the displayed size and crop. Asset lists return nextCursor when another page exists. Keep the same filters when continuing a query. The older --offset flag remains accepted for existing scripts. You can also create folders, move assets, and remove them:

Keep images out of the repository

fimo validate, which fimo deploy runs first, warns when image or video files (.png, .jpg, .jpeg, .webp, .gif, .avif, .mp4, .webm, .mov) would be committed with your code:
Upload each file, replace its path in your code with the returned URL, then delete the file from the repository. Library images get responsive optimization through <Image>, and your team can find, reuse, and replace them in Studio. The agent skills that ship with the CLI tell coding agents to upload local images and videos with fimo assets upload instead of committing them. The warning does not block validation or deploys. It skips files git ignores, build output, SVGs, and files that browsers or frameworks must read from the repository: favicons, apple-touch-icon and app icons, and framework metadata images such as opengraph-image and twitter-image. With --json, the warning is in warnings[] as text and in data.warnings[] with the code media/committed-to-repo and the list of files.

Let agents read existing assets

When an agent needs to understand a document or media file, it can read the supported interpretation already associated with a Media Library asset:
The result is bounded. Follow nextCursor until complete is true for a complete read, or use --query for one targeted question. Use fimo assets open <asset-id> --download when the agent needs the original file instead of its canonical interpretation. Archives are downloaded and inspected in the agent’s sandbox rather than extracted on the server.

Supported file types

Asset reading covers these common file types:
  • Images: .png, .jpg, .jpeg, .webp, .avif
  • Documents and data: .pdf, .doc, .docx, .xls, .xlsx, .ppt, .pptx, .epub, .odt, .ods, .odp, .rtf, .html, .htm, .csv, .md, .markdown, .json, .txt
  • Archives: .zip
  • Audio: .mp3, .wav, .aiff, .aif, .aac, .ogg, .flac
  • Video: .mp4, .mpeg, .mpg, .mov, .avi, .flv, .webm, .wmv, .3gp
  • 3D models: .glb, .gltf, .fbx, .obj, .stl, .ply
Chat model input support can vary. If a model cannot accept a direct attachment, use a model that supports the format or read the stored asset interpretation with fimo assets read.

Size limits

No single file may exceed 50 MiB, wherever it is uploaded from — the CLI, the Media Library, or a chat attachment. Chat attachments are held to a tighter limit per file type, because the whole message has to fit in one turn: One message carries at most 10 attachments totalling 20 MiB. A file over any of these limits is refused before it is uploaded, and Fimo names the file, its size, and the limit it missed. A site’s total stored media is a separate, plan-based allowance. Reaching it refuses new uploads with the figures involved, whatever each file’s size.

Generate an image

Image commands can also edit an existing image, remove its background, or upscale it. Run the task with --help to see the inputs supported by your installed CLI. Preview a generation request without creating an asset:

Generate a video

Add --image <asset-id-or-url> to start from an image. Other video tasks can animate an image from source motion or replace people while keeping the source motion.

Choose a quality

Replace or remove assets safely

Check where an asset is referenced before you remove it:
The scan covers the Current Branch, Main, and Live, and reports coverage and a reference count for each. Other Branches and code references are not checked, so use the result as guidance for those three places only.
fimo assets remove <asset-id> removes the asset from the current Branch. It does not replace references automatically. Reference counts and incomplete scan results do not block it. Main, Live, other Branches, and the stored file remain unchanged. fimo assets remove <asset-id> --permanent deletes the asset from the site and cannot be undone. The command asks for confirmation. Pass --yes only for an already-approved non-interactive run:
With both --replace-with and --permanent, Fimo first updates known content references in every active Branch and Live, then deletes the source file. If a replacement fails, Fimo keeps the source file so the command is safe to retry. fimo assets delete remains an alias for fimo assets remove for existing scripts. For every media task, option, and supported limit, see the CLI reference.

What’s next

Media library

Upload, sort, and reuse files in Studio.

Content

Attach assets to content fields.

Frameworks

Render media with the right adapter.