Replace and delete files
Replace swaps a file's content while keeping its identity, so every place that uses it updates at once. Delete removes the file from the library; places that used it show an empty placeholder until you pick another file. You can also rename files at any time.
Replace and delete files
Replace swaps a file's content while keeping its identity, so every place that uses it updates at once. Delete removes the file from the library; places that used it show an empty placeholder until you pick another file. You can also rename files at any time.
When to use
- Replace: a new logo, an updated price list, a better photo — same purpose, new file.
- Delete: files you no longer need; keeping the library clean.
- Rename: clearer names for the asset pickers.
How to replace a file
- Open Assets and select the file.
- In the details panel click Replace file and choose the new file. It must pass the same checks as any upload (type, 25 MB).
- The library confirms "File replaced everywhere it's used".
What changes:
- The asset keeps its id, folder and alt text. Every Image component, theme slot (logo, favicon, fonts), SEO image and PWA icon that references the asset shows the new file immediately in the builder and after the next publish.
- The file's public URL changes (a new storage path). Places where you pasted the old URL — an Open URL or Download file action, an Image with Source = URL — keep pointing at the old address and must be updated by hand.
- Images are re-optimised (new WebP variant, placeholder, dimensions); old variants are removed.
- Replacing a PNG with an SVG (or any type change) is allowed; the type shown in the library updates.
How to delete a file
- Select the file and click Delete file.
- Confirm. The message reminds you: Components that use this file will show an empty placeholder. Published versions keep working until you publish again.
What happens:
- The asset disappears from the library and from the project definition.
- Image components that used it show the empty image placeholder ("Choose an image in Properties" in the editor); theme slots fall back to defaults (for example the initial letter instead of the logo).
- The published app is unaffected until you publish a new version, because the file's bytes are kept while a published version may still reference them.
- The deletion is recorded in the audit log.
To avoid surprises, check where a file is used before deleting (search the pages for its name) or replace it instead.
How to rename a file
Edit File name in the details panel. Only the display name changes; references and the URL are untouched. Names are cleaned of unusual characters.
Details · hero-kitchen.jpg [Replace file] [Download original] [Delete file]
Common mistakes
- Deleting then re-uploading "the same" file. The new upload is a new asset; every component must be re-pointed. Use Replace file.
- Expecting the old URL to keep working after a replace. Update pasted URLs.
- Deleting the logo or favicon. The theme reverts to defaults; publish validation may flag missing assets.
Related
Advanced
Replace reuses the asset id through createUpload({ replaceAssetId }) + completeUpload, which writes a new storage key, deletes the old key and its .webp/.avif variants, and issues an update_asset command. Delete issues delete_asset (if the asset is in the draft) and sets deletedAt on the row without removing the bytes; audit records asset.deleted.