Skip to main content
fal provides persistent file storage at /data that is shared across all your runners and applications. Use it to store model weights, datasets, and any files your apps need.

Using /data in Your App

The /data directory is automatically mounted on every runner. Files you write there persist between requests and across deployments.
import fal

class MyModel(fal.App):
    machine_type = "GPU-A100"

    def setup(self):
        import torch
        model_path = "/data/models/my-model.pt"

        if os.path.exists(model_path):
            self.model = torch.load(model_path)
        else:
            self.model = download_and_save(model_path)
/data is an eventually-consistent distributed filesystem. When writing files, use atomic operations (write to a temp file, then move) to avoid race conditions if multiple runners write simultaneously.

Uploading Files

Dashboard

Navigate to Dashboard > Files to manage your files visually:
  • Drag and drop files to upload
  • Upload from URL to pull files from external sources
  • Organize files in folders
  • Download, copy paths, or delete files

SDK

Upload files programmatically from your code:
from fal.toolkit import File

# Upload from local file
file = File.from_path("path/to/file.bin")
print(file.url)

# Upload from bytes
file = File.from_bytes(data, "output.png", content_type="image/png")
print(file.url)

CLI

Upload and manage files using the fal CLI:
# List files
fal files list

# List files in a directory
fal files list models/

# Upload a file
fal files upload local-file.bin remote-path/file.bin

REST API

For direct integration, use the Platform APIs:
  • POST /serverless/files/file/local/{target_path} — Upload a file directly
  • POST /serverless/files/file/url/{file} — Upload from a URL
  • GET /serverless/files/list — List files
  • GET /serverless/files/file/{file} — Download a file

Platform API Reference

See the full file management API specification

Storage Details

PropertyValue
Mount path/data on all runners
Shared acrossAll apps and runners in your account
ConsistencyEventually consistent
Max file sizeUp to 50 GB (resumable upload), ~1 TB (multipart)
PersistenceFiles persist until you delete them

CDN File Uploads

When your app generates output files (images, videos, audio), they’re uploaded to fal’s CDN and returned as URLs. These are separate from /data storage — see Media Expiration to control how long CDN files are retained.