File Operations in Supabase

From the Supabase cheat sheet · Storage · verified Jul 2026

File Operations

Upload, download, and manage files

typescript
// Upload file
const { data, error } = await supabase.storage
  .from('avatars')
  .upload('public/avatar.png', file)

// Download file
const { data } = await supabase.storage
  .from('avatars')
  .download('public/avatar.png')

// Get public URL
const { data } = supabase.storage
  .from('avatars')
  .getPublicUrl('public/avatar.png')
📁 S3-compatible object storage
🖼️ Automatic image transformations
🔗 Signed URLs for private files
⚡ CDN distribution included
Back to the full Supabase cheat sheet