---
title: Migrate from Supabase Storage to Vercel Blob
description: Migrate from Supabase Storage to Vercel Blob in TypeScript or Python, including buckets, uploads, public and signed URLs, access rules, and a staged cutover.
keywords: ["Vercel Blob","Supabase Storage","migrate from Supabase Storage","object storage migration","file uploads","signed URLs"]
url: "https://vercel.com/kb/guide/migrate-from-supabase-storage-to-vercel-blob"
published: 2026-12-03
last_updated: 2026-12-03
authors: Ben Sabic
related_resources:
  - title: "The Complete Guide to Vercel Blob"
    url: "/kb/guide/vercel-blob"
    description: "Vercel Blob stores and serves files of any size through Vercel's global network. Learn how Blob works, what it costs, and how to upload files from your server or directly from the browser."
  - title: "Build with Vercel Blob on Next.js"
    url: "/kb/guide/vercel-blob-nextjs"
    description: "Deploy the Vercel Blob Next.js Starter and learn how client uploads store images securely in a private Blob store."
  - title: "Store and serve files from Python with Vercel Blob"
    url: "/kb/guide/python-and-vercel-blob"
    description: "Upload, list, stream, and protect files from a Python app with Vercel Blob, including private per-user storage in FastAPI."
  - title: "Build a private file upload app with Vercel Blob"
    url: "/kb/prompts/build-private-file-upload-app"
    description: "Build an owner-only file library with private Vercel Blob storage, authenticated downloads, and checks for cross-user access."
  - title: "Use private Vercel Blob storage"
    url: "https://vercel.com/docs/vercel-blob/private-storage"
    description: "Serve private files through an authenticated application route."
install_vercel_plugin: npx plugins add vercel/vercel-plugin
search_with_vercel_cli: npx vercel@latest kb search "<query>"
read_with_vercel_cli: "npx vercel@latest kb inspect migrate-from-supabase-storage-to-vercel-blob"
---

To move files from [Supabase Storage](https://supabase.com/docs/guides/storage) to [Vercel Blob](https://vercel.com/docs/vercel-blob), copy each bucket's objects into a Blob store, then update your application's `supabase.storage` calls to use Vercel's TypeScript or Python SDK and adapt uploads, URLs, and access rules. Review the [migration limitations](#what-doesn%27t-map-from-supabase-storage) before starting if your application relies on image transformations, the S3 protocol, object versioning, or custom object metadata.

Both products store files behind a CDN, with different access controls. Supabase applies Row Level Security (RLS) to user-authorized storage operations; public reads, signed URL transfers, and requests using a secret or service-role key bypass those checks. Supabase buckets can switch between public and private. Blob stores keep the access mode chosen at creation, and your application checks permissions before performing privileged operations or issuing signed URLs.

You can use Vercel Blob from an application on any host. Your backend connects through the SDK using [Vercel credentials](https://vercel.com/docs/vercel-blob/using-blob-sdk#authentication), while files are stored and served from Vercel's infrastructure. Keep your database and Supabase Auth in place.

## Prerequisites

Before you begin, make sure you have a [Vercel account](https://vercel.com/signup) and your Supabase project's secret key or legacy service-role key for reading the source objects.

Use Node.js 22.12 or later for the migration scripts and the latest [Vercel CLI](https://vercel.com/docs/cli). The Python examples also require Python 3.11 or later.

## Migrate with your agent

Use this prompt in your application's repository to have a coding agent check where Supabase Storage is used and prepare the migration:

### Agent prompt

```txt
Use https://vercel.com/kb/guide/migrate-from-supabase-storage-to-vercel-blob to migrate this application to Vercel Blob.

1. You can also read the migration guide using the Vercel CLI: `npx vercel@latest kb inspect migrate-from-supabase-storage-to-vercel-blob`.
2. Inventory `supabase.storage` and `storage.from_()` call sites and hardcoded `/storage/v1/` URLs, including buckets, uploads, downloads, lists, deletes, moves, copies, public URLs, signed URLs, signed upload URLs, cache settings, content types, and upsert options. Preserve the application's language and authorization checks. Leave Supabase database and Auth calls unchanged.
3. Identify features that need a different design, including RLS policies on `storage.objects`, image transformations, resumable (TUS) uploads, S3 protocol clients, object versioning, custom object metadata, object ownership, and database triggers on `storage.objects`. Ask for a decision only where that choice blocks implementation.
4. Keep both providers behind one application module. Record which provider holds each file, and keep the Supabase path available until I approve cutover.
5. Port one call site at a time. Check the access mode, pathnames, overwrite behavior, cache settings, units, and error handling against the guide and the SDK references: https://vercel.com/docs/vercel-blob/using-blob-sdk and https://vercel.com/docs/vercel-blob/python-sdk-reference
6. Keep the source authoritative until the final copy is verified. Plan a write pause or an ordered change log covering creates, replacements, metadata updates, renames, and deletes. Preflight pathname mappings, verify per-file content and permissions, and reconcile the same changes before any rollback. Do not remove source data or revoke credentials without approval.
7. Run local checks first. Describe any live test and the resources it creates before running it. Report the results, remaining configuration, and cutover plan. Do not switch production traffic without my approval.
```

## How Supabase Storage features map to Vercel Blob

Buckets map to Blob stores, the Supabase secret key maps to Vercel project credentials, and object paths map to pathnames. Other features, such as RLS policies and image transformations, require a [different approach](#what-doesn%27t-map-from-supabase-storage).

You can keep using TypeScript or Python. The mappings use TypeScript names for both SDKs, and [step 4](#4.-replace-upload,-download,-list,-and-delete-calls) lists the Python names.

### Projects, buckets, and credentials

Replace each bucket with a Blob store that has the same access, and replace the Supabase secret key with Vercel project credentials.

| Supabase Storage                                                       | Vercel Blob                                                                                                                                                                   | What you change                                                                                                                              |
| ---------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------- |
| Supabase project that holds your buckets                               | Vercel team that owns your Blob stores                                                                                                                                        | Connect each store to the Vercel projects that use it. One project can use several stores.                                                   |
| Bucket                                                                 | [Blob store](https://vercel.com/docs/vercel-blob), or a pathname prefix inside a store                                                                                        | Create a store for each bucket, or combine buckets with the same access in one store and keep the bucket name as the first pathname segment. |
| Private bucket, the default                                            | [Private store](https://vercel.com/docs/vercel-blob/private-storage)                                                                                                          | Access is set when you create the store and can't change later.                                                                              |
| Public bucket, set with `public: true`                                 | [Public store](https://vercel.com/docs/vercel-blob/public-storage)                                                                                                            | Anyone with a public blob's URL can read it, as with a public bucket.                                                                        |
| Secret key in `SUPABASE_SECRET_KEY`, or the legacy `service_role` key  | [OIDC token](https://vercel.com/docs/vercel-blob/using-blob-sdk#authentication) in `VERCEL_OIDC_TOKEN` with `BLOB_STORE_ID`, or a read-write token in `BLOB_READ_WRITE_TOKEN` | Run `vercel link` and `vercel env pull` for local development. Use the read-write token for backends hosted outside Vercel.                  |
| Publishable key and a user's JWT in the browser                        | No browser credential                                                                                                                                                         | The browser uploads with a short-lived client token or presigned URL that your server issues.                                                |
| RLS policies on `storage.objects`                                      | No equivalent                                                                                                                                                                 | Authorize each request in your application code, as step 7 describes.                                                                        |
| Project region                                                         | Store `region`, with one of [19 region IDs](https://vercel.com/docs/regions#region-list) such as `iad1`                                                                       | Choose the region when you create the store. It can't change later.                                                                          |
| Object path inside a bucket, such as `reports/q1.pdf` in `documents`   | Pathname, such as `documents/reports/q1.pdf`                                                                                                                                  | Pathnames can be up to 950 characters and can't contain `//`.                                                                                |
| Folders as key prefixes                                                | Folders as pathname prefixes                                                                                                                                                  | Keep the `/` separators. Neither product needs folders created first.                                                                        |
| `fileSizeLimit` and `allowedMimeTypes` on a bucket                     | `maximumSizeInBytes` and `allowedContentTypes` on a client token or signed token                                                                                              | Set the limits where your server issues the token. Validate server uploads in your route.                                                    |
| Global file size limit of 50 MB on Free, or up to 500 GB on paid plans | 5 TB per blob                                                                                                                                                                 | Use multipart uploads for files above 100 MB.                                                                                                |
| `owner_id`, `user_metadata`, and `created_at` in `storage.objects`     | Pathname, content type, size, upload time, cache settings, and ETag                                                                                                           | Keep ownership and custom metadata in your own database table.                                                                               |

### Uploads and file operations

Most file methods have a direct replacement. Blob methods throw errors instead of returning an `error` property, and most take an `access` option that must match the store.

| Supabase Storage                                                                     | Vercel Blob                                                                                                   | What you change                                                                                                                                                                         |
| ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `upload()`, which rejects an existing path by default                                | `put()`, which throws for an existing pathname by default                                                     | Rename the call and pass `access`.                                                                                                                                                      |
| `upsert: true`, or `update()`                                                        | `allowOverwrite: true`                                                                                        | Keep overwrites explicit.                                                                                                                                                               |
| `cacheControl: '3600'`, a string of seconds with a 1-hour default                    | `cacheControlMaxAge: 3600`, a number of seconds with a 1-month default and a 60-second minimum                | Pass the value you rely on, because the Blob default is longer.                                                                                                                         |
| `contentType`                                                                        | `contentType`, inferred from the pathname's extension when omitted                                            | Keep file extensions in pathnames, or pass the type.                                                                                                                                    |
| Standard uploads, recommended up to 6 MB, and resumable TUS uploads for larger files | `put()` or `upload()` with `multipart: true`                                                                  | Use multipart uploads to retry failed parts. This high-level call starts a new upload each time; decide how to replace TUS recovery after a page reload before removing the TUS client. |
| Browser `upload()` under an RLS `INSERT` policy                                      | [Client upload](https://vercel.com/docs/vercel-blob/client-upload) with `upload()` from `@vercel/blob/client` | Add a route that authorizes the user and issues the token.                                                                                                                              |
| `createSignedUploadUrl()` and `uploadToSignedUrl()`, valid for 2 hours               | Client token from `handleUpload()`, valid for 1 hour by default                                               | Set `validUntil` to change the lifetime.                                                                                                                                                |
| `download()`, which returns a `Blob`                                                 | `get()`, which returns a stream and the blob's details                                                        | Read `result.stream`. `get()` returns `null` for a missing blob.                                                                                                                        |
| `info()` and `exists()`                                                              | `head()`                                                                                                      | `head()` throws `BlobNotFoundError` for a missing blob.                                                                                                                                 |
| `list()` with `limit` and `offset`, one folder level at a time                       | `list()` with `prefix`, `limit`, and `cursor`                                                                 | Lists are recursive by default and return up to 1,000 blobs per page in pathname order. Use `mode: 'folded'` for one folder level.                                                      |
| `remove()` with an array of paths                                                    | `del()` with a pathname, a URL, or an array of either                                                         | `del()` doesn't throw for a missing blob.                                                                                                                                               |
| `move()`                                                                             | `rename()`                                                                                                    | Pass `access`. `rename()` works within one store and, like a copy, doesn't carry over content type or cache settings, so pass them again.                                               |
| `copy()`                                                                             | `copy()`                                                                                                      | Pass `access`. Content type and cache settings aren't copied from the source, so pass them again.                                                                                       |

### URLs and delivery

Public blob URLs replace `getPublicUrl()`, and Vercel Signed URLs or an authenticated route replace `createSignedUrl()`.

| Supabase Storage                                                          | Vercel Blob                                                                                                                                         | What you change                                                                                                                                        |
| ------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------ |
| `getPublicUrl()`, built from the bucket and path                          | `url` returned by `put()`, `head()`, and `list()`                                                                                                   | Store the returned URL or the pathname. Public URLs use `https://<store-id>.public.blob.vercel-storage.com/<pathname>`.                                |
| `createSignedUrl(path, expiresIn)`, with the lifetime in seconds          | [`issueSignedToken()` and `presignUrl()`](https://vercel.com/docs/vercel-blob/vercel-signed-urls), with `validUntil` as a timestamp in milliseconds | Signed URLs last up to 7 days. Cache the signed token and sign each URL locally.                                                                       |
| `/object/authenticated/` URLs that take a user's JWT                      | A route in your application that checks the user and streams `get()`                                                                                | Private blob URLs need store credentials or a signature.                                                                                               |
| `download` option, or `?download=` on a URL                               | `downloadUrl`, or `?download=1` on a URL                                                                                                            | To set a custom file name, serve the blob through a route and set `Content-Disposition`.                                                               |
| `transform` option and `/render/image/` URLs                              | No request-time transformations                                                                                                                     | Use `next/image` with public blob URLs, or resize at upload with `putImage()`. See Image transformations under What doesn't map from Supabase Storage. |
| Smart CDN on paid plans, which clears an updated object within 60 seconds | CDN cache of up to 1 month by default, cleared within 60 seconds of an overwrite or delete                                                          | Browsers keep their cached copy on both products, so write changed files to a new pathname. Blobs over 512 MB are never cached.                        |
| `cacheNonce`, or a unique query string                                    | New versioned pathname, or `useCache: false` in `get()` for a private store                                                                         | Write changed public files to a new pathname. For an immediate private server read after an overwrite, set `useCache: false`.                          |
| HTML files served as plain text                                           | HTML files served as downloads                                                                                                                      | Neither product hosts HTML pages.                                                                                                                      |

## Steps

### 1\. Find where your application uses Supabase Storage

Search for Supabase Storage calls, hardcoded storage URLs, and TUS clients, then trace aliases through your code to identify features that need a replacement.

```bash
grep -rnE \
  "\.storage($|[^A-Za-z0-9_])|/storage/v1/|storage\.supabase\.co|tus-js-client" \
  --include="*.py" --include="*.ts" --include="*.tsx" \
  --include="*.js" --include="*.jsx" --include="*.mjs" \
  --exclude-dir=node_modules --exclude-dir=.venv \
  --exclude-dir=venv --exclude-dir=.next .
```

Also check `.env` files for `SUPABASE_URL`, `SUPABASE_SECRET_KEY`, and the legacy `SUPABASE_SERVICE_ROLE_KEY`. Check `next.config.js` for `remotePatterns` or an image loader that points at `supabase.co`, and check your database for columns that store object paths or public URLs.

Next, measure what you're moving. Run this query in the Supabase SQL Editor to count the current live objects and total size in MiB for each bucket. It excludes retained versions, delete markers, and the empty-folder placeholders that the copy script skips:

```sql
select
  bucket_id,
  count(*) as objects,
  (
    sum((metadata->>'size')::bigint) / 1048576.0
  )::numeric(10, 2) as total_size_mib
from storage.objects
where archived_at is null
  and is_delete_marker = false
  and name <> '.emptyFolderPlaceholder'
  and name not like '%/.emptyFolderPlaceholder'
group by bucket_id
order by total_size_mib desc;
```

List each bucket's access and limits, because they decide which Blob stores you create:

```sql
select id, public, file_size_limit, allowed_mime_types
from storage.buckets
order by id;
```

Match what you find to the steps that follow:

| In your code or project                                                                                                           | Go to                                  |
| --------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------- |
| Buckets, bucket settings, or the Supabase secret key                                                                              | Step 2                                 |
| `upload()`, `download()`, `list()`, `remove()`, `move()`, or `copy()` in server code                                              | Step 4                                 |
| `upload()` in browser code, `createSignedUploadUrl()`, `uploadToSignedUrl()`, or a TUS client                                     | Step 5                                 |
| `getPublicUrl()`, `createSignedUrl()`, or `/storage/v1/object/` URLs                                                              | Step 6                                 |
| RLS policies on `storage.objects`                                                                                                 | Step 7                                 |
| Existing objects in your buckets                                                                                                  | Step 8                                 |
| Object paths or URLs saved in your database                                                                                       | Step 9                                 |
| `transform` options, `/render/image/` URLs, the S3 endpoint, versioned buckets, `user_metadata`, or triggers on `storage.objects` | What doesn't map from Supabase Storage |

### 2\. Create a Blob store and authenticate

Match each Supabase bucket's access mode in its Blob store. For private files, replace storage RLS with permission checks in your app.

Link your local directory to the Vercel project that will use the store:

```bash
vercel link
```

Create a private store and connect it to all three project environments with `--yes`. For files anyone may read, change the access option to `--access public`:

```bash
vercel blob create-store uploads --access private --yes
```

Choose the store’s [region](https://vercel.com/docs/regions#region-list) with `--region` if the default `iad1` does not suit the workload. Access mode and region are fixed at creation. To connect selected environments, use `--environment` for each one instead of `--yes`.

Pull the Development environment variables into `.env.local`:

```bash
vercel env pull
```

#### Local development and deployments on Vercel

The SDK uses `BLOB_STORE_ID` with the project’s OIDC token for server-side requests. Vercel manages deployed tokens, and the SDK can refresh local credentials using your CLI sign-in. Load `.env.local` when running a local script, as the commands in the SDK examples show.

If you create the store in the dashboard, its connection initially includes Production and Preview. Add Development under **Projects > Update Project Connection** before pulling local variables.

#### Backends on another host

Set the store’s `BLOB_READ_WRITE_TOKEN` in the backend’s environment. The CLI setup supplies this variable; dashboard connections require **Add a read-write token env var to this connection**. The SDK reads it automatically; keep it server-side.

Browser uploads through `handleUpload()` also require this token. For an OIDC-only connection, use `handleUploadPresigned()` instead.

#### More than one store

Give each additional connection a **Custom Environment Variable Prefix** so its credentials do not replace another store’s variables. For a connection prefixed `PUBLIC_FILES`, pass its store ID on calls that use OIDC:

```javascript
import { put } from '@vercel/blob';

const storeId = process.env.PUBLIC_FILES_STORE_ID;
await put('reports/summary.txt', 'Quarterly summary', {
  access: 'public',
  storeId,
});
```

For another host, pass the corresponding prefixed read-write token instead. Keep the source credentials through verification and the rollback period.

### 3\. Install the Vercel Blob SDK

Install `@vercel/blob` for TypeScript and JavaScript:

**pnpm**

```bash
pnpm i @vercel/blob
```

**npm**

```bash
npm i @vercel/blob
```

**yarn**

```bash
yarn add @vercel/blob
```

**bun**

```bash
bun add @vercel/blob
```

For Python, install `vercel`, which includes the Blob SDK, and `python-dotenv` to load local credentials. Use Python 3.11 or later for these examples:

**uv**

```bash
uv add vercel python-dotenv
```

**pip**

```bash
pip install vercel python-dotenv
```

Keep the `@supabase/supabase-js` or `supabase` package while both providers run, and afterward if you use other Supabase services.

### 4\. Replace upload, download, list, and delete calls

Replace each `supabase.storage.from(bucket)` call in your server code with the corresponding `@vercel/blob` function. Blob functions have no bucket selector, because the project's credentials select the store.

Route every storage operation through one module in your application, and add a flag that selects Supabase Storage or Vercel Blob for new files. Add the Blob calls beside the Supabase calls, and keep the Supabase path until step 10.

#### TypeScript SDK calls

| Task                   | Supabase Storage                            | Vercel Blob                                           |
| ---------------------- | ------------------------------------------- | ----------------------------------------------------- |
| Import                 | `createClient` from `@supabase/supabase-js` | Functions from `@vercel/blob`                         |
| Select a bucket        | `supabase.storage.from('documents')`        | No call. Credentials select the store.                |
| Upload a file          | `upload(path, body, options)`               | `put(pathname, body, { access })`                     |
| Overwrite a file       | `upsert: true`, or `update()`               | `allowOverwrite: true`                                |
| Set the cache lifetime | `cacheControl`, a string of seconds         | `cacheControlMaxAge`, a number of seconds             |
| Download a file        | `download(path)`                            | `get(pathname, { access })`                           |
| Read file details      | `info(path)` or `exists(path)`              | `head(pathname)`                                      |
| List files             | `list(folder, { limit, offset })`           | `list({ prefix, limit, cursor })`                     |
| Delete files           | `remove([paths])`                           | `del([pathnames])`                                    |
| Move a file            | `move(from, to)`                            | `rename(from, to, { access })`                        |
| Copy a file            | `copy(from, to)`                            | `copy(from, to, { access })`                          |
| Get a public URL       | `getPublicUrl(path)`                        | `url` on the result of `put()`, `head()`, or `list()` |
| Create a signed URL    | `createSignedUrl(path, seconds)`            | `issueSignedToken()`, then `presignUrl()`             |
| Handle a failure       | `error` on the returned object              | A thrown error, such as `BlobNotFoundError`           |

The server-upload routes use `getCurrentUser` from your application's `@/lib/auth` module. Implement it to return `{ id: string }` for an authenticated user or `null`, using your existing session lookup. Both routes validate the file and write under that user's encoded ID; the Supabase version uses the secret key to upload to a private bucket:

```typescript
import { getCurrentUser } from '@/lib/auth';
import { createClient } from '@supabase/supabase-js';

const supabase = createClient(
  process.env.SUPABASE_URL!,
  process.env.SUPABASE_SECRET_KEY!,
);

export async function POST(request: Request) {
  const user = await getCurrentUser();
  if (!user) return new Response('Unauthorized', { status: 401 });

  const form = await request.formData();
  const file = form.get('file');
  if (!(file instanceof File) || !file.name ||
      /[\/\\]/.test(file.name) || ['.', '..'].includes(file.name)) {
    return new Response('Invalid file', { status: 400 });
  }

  const { data, error } = await supabase.storage
    .from('documents')
    .upload(`${encodeURIComponent(user.id)}/${file.name}`, file, {
      cacheControl: '3600',
      upsert: false,
    });
  if (error) {
    return Response.json({ error: error.message }, { status: 400 });
  }

  return Response.json(data);
}
```

The Vercel version keeps the same per-user path and adds the bucket name as its first pathname segment. Implement `saveUploadedFile` in `@/lib/files` to upsert `{ userId, pathname, url }` by pathname in your database. This application function records ownership for later reads and deletes:

```typescript
import { saveUploadedFile } from '@/lib/files';
import { getCurrentUser } from '@/lib/auth';
import { put } from '@vercel/blob';

export async function POST(request: Request) {
  const user = await getCurrentUser();
  if (!user) return new Response('Unauthorized', { status: 401 });

  const form = await request.formData();
  const file = form.get('file');
  if (!(file instanceof File) || !file.name ||
      /[\/\\]/.test(file.name) || ['.', '..'].includes(file.name)) {
    return new Response('Invalid file', { status: 400 });
  }

  const pathname = `documents/${encodeURIComponent(user.id)}/${file.name}`;
  const blob = await put(pathname, file, {
    access: 'private',
    cacheControlMaxAge: 3600,
  });

  await saveUploadedFile({
    userId: user.id,
    pathname: blob.pathname,
    url: blob.url,
  });
  return Response.json(blob);
}
```

The `access` value must match the store. `put()` returns the blob's `pathname`, `url`, `downloadUrl`, `contentType`, and `etag`, and it throws if the upload fails. Keep these server-side permission checks when adapting the routes, because both SDK calls use credentials that bypass per-user storage rules.

Save this credential check as `blob-check.mjs` before porting more call sites:

```javascript
import { get, put } from '@vercel/blob';

const blob = await put('migration-check/hello.txt', 'Hello from Vercel Blob', {
  access: 'private',
  allowOverwrite: true,
});
console.log(blob.pathname);

const result = await get(blob.pathname, { access: 'private' });
if (result?.statusCode !== 200) throw new Error('Blob not found');
console.log(await new Response(result.stream).text());
```

Run it with the environment file loaded:

```bash
node --env-file=.env.local blob-check.mjs
```

The script prints `migration-check/hello.txt` and `Hello from Vercel Blob`. For a public store, change both `access` values to `'public'`.

#### Python SDK calls

The Vercel Python samples import the `blob` module from the `vercel` package. For synchronous code, import `sync` from `vercel.blob` as `blob` and remove `await`.

| Task                   | Supabase Storage                            | Vercel Blob                                                             |
| ---------------------- | ------------------------------------------- | ----------------------------------------------------------------------- |
| Import                 | `create_client` from `supabase`             | `blob` from `vercel`                                                    |
| Select a bucket        | `supabase.storage.from_("documents")`       | No call. Credentials select the store.                                  |
| Upload a file          | `upload(path, file, file_options)`          | `blob.put_blob(pathname, body, access=...)`                             |
| Overwrite a file       | `"upsert": "true"` in `file_options`        | `allow_overwrite=True`                                                  |
| Set the cache lifetime | `"cache-control": "3600"` in `file_options` | `cache_control_max_age=3600`                                            |
| Download a file        | `download(path)`, which returns `bytes`     | `blob.get_blob(pathname, access=...)`, then `.body`                     |
| Stream a large file    | No streaming call                           | `blob.stream_blob(pathname, access=...)`                                |
| Read file details      | `info(path)` or `exists(path)`              | `blob.head_blob(pathname)`                                              |
| List files             | `list(folder, options)`                     | `blob.query_blobs(prefix=...)`, which follows pagination                |
| Delete files           | `remove([paths])`                           | `blob.delete_blob([pathnames])`                                         |
| Copy a file            | `copy(from_path, to_path)`                  | `blob.copy_blob(source, pathname, access=...)`                          |
| Move a file            | `move(from_path, to_path)`                  | `copy_blob()`, then `delete_blob()`                                     |
| Create a signed URL    | `create_signed_url(path, seconds)`          | Not in the Python SDK. Use the JavaScript SDK or `vercel blob presign`. |

Supabase's Python client uploads and downloads a file with the same options as the JavaScript client:

```python
import os

from supabase import create_client

supabase = create_client(
    os.environ["SUPABASE_URL"], os.environ["SUPABASE_SECRET_KEY"]
)

with open("./q1.pdf", "rb") as f:
    supabase.storage.from_("documents").upload(
        file=f,
        path="reports/q1.pdf",
        file_options={"cache-control": "3600", "upsert": "false"},
    )

data = supabase.storage.from_("documents").download("reports/q1.pdf")
print(len(data))
```

Save the Vercel version as `blob_example.py` in your linked project directory:

```python
import asyncio

from dotenv import load_dotenv
from vercel import blob

load_dotenv(".env.local")


async def main() -> None:
    with open("./q1.pdf", "rb") as f:
        uploaded = await blob.put_blob(
            "documents/reports/q1.pdf",
            f.read(),
            access="private",
            cache_control_max_age=3600,
        )
    print(uploaded.pathname)

    file = await blob.get_blob("documents/reports/q1.pdf", access="private")
    print(len(file.body))


asyncio.run(main())
```

Run the script from your project directory to load `.env.local`:

```bash
python blob_example.py
```

The script prints `documents/reports/q1.pdf` and the file's size in bytes. The Python SDK doesn't include client uploads, signed URLs, or `rename()`, so keep those operations in a TypeScript route or use the Vercel CLI.

#### Overwrites and cache settings

Supabase's `upload()` returns a `400 Asset Already Exists` error for an existing path unless you set `upsert`. Blob's `put()` also rejects an existing pathname by default. Pass `allowOverwrite: true` to replace the blob, or `addRandomSuffix: true` to give each upload a unique pathname.

Supabase sets a cache lifetime of 1 hour by default, and Blob sets 1 month. Pass `cacheControlMaxAge` for files you overwrite, such as a JSON file that changes every few minutes. An overwritten or deleted blob can take up to 60 seconds to clear from the CDN, and browsers keep their copy until it expires, so write changed files to a new pathname where you can.

#### Results and errors

Supabase methods return an object with `data` and `error`. Blob functions return the result directly and throw on failure, so replace `if (error)` checks with `try` and `catch`:

| Blob function | Behavior for a missing blob |
| ------------- | --------------------------- |
| `get()`       | Returns `null`              |
| `head()`      | Throws `BlobNotFoundError`  |
| `del()`       | Returns without an error    |

#### Server upload size

Vercel Functions have a 4.5 MB request body limit. If your route receives a larger file before calling `put()`, the request fails with `413 FUNCTION_PAYLOAD_TOO_LARGE` before your code runs. Client uploads send the file bytes directly to Blob, so that Function limit doesn't apply to the transfer.

#### Lists, moves, and deletes

Supabase's `list()` uses `offset` to page through one folder level. Blob's `list()` uses a cursor to list all files under a prefix in pathname order:

```javascript
import { copy, del, head, list, rename } from '@vercel/blob';

let cursor;
do {
  const page = await list({ prefix: 'documents/reports/', cursor });
  for (const blob of page.blobs) console.log(blob.pathname, blob.size);
  cursor = page.hasMore ? page.cursor : undefined;
} while (cursor);

const details = await head('documents/reports/q1.pdf');
console.log(details.size, details.contentType, details.uploadedAt);

await rename('documents/reports/q1.pdf', 'documents/archive/q1.pdf', {
  access: 'private',
});
await copy('documents/reports/q2.pdf', 'documents/archive/q2.pdf', {
  access: 'private',
});
await del(['documents/reports/q3.pdf']);
```

To browse one folder level, as Supabase's `list()` does, pass `mode: 'folded'` and read `folders` from the result. Blob has no equivalent to the `sortBy` and `search` options, so sort and filter in your application or query your own database table.

`rename()` and `copy()` work inside one store and don't carry over the source's content type or cache lifetime, so pass `contentType` and `cacheControlMaxAge` again if you set them at upload. To move a blob between stores, such as from a private store to a public one, read it with `get()` and write it to the other store with `put()`.

### 5\. Replace browser uploads with client uploads

On Supabase, the browser uploads with the publishable key and the user's session, and an RLS `INSERT` policy decides whether to accept the file. On Vercel, the browser asks a route in your application for a short-lived client token, and that route decides whether to issue one. The file then goes from the browser to Vercel Blob without passing through your server, so the 4.5 MB request limit doesn't apply.

This browser code uploads an avatar to a public Supabase bucket:

```javascript
const { data, error } = await supabase.storage
  .from('avatars')
  .upload(`${user.id}/${file.name}`, file, {
    cacheControl: '3600',
    upsert: false,
  });
```

On Vercel, call `upload()` from `@vercel/blob/client` and point it at your token route:

```javascript
import { upload } from '@vercel/blob/client';

const pathname = `avatars/${encodeURIComponent(user.id)}/${file.name}`;
const blob = await upload(pathname, file, {
  access: 'public',
  handleUploadUrl: '/api/avatar/upload',
});
console.log(blob.url);
```

Save the token route as `app/api/avatar/upload/route.ts`. Reuse your application's `getCurrentUser` session lookup from `@/lib/auth`, which returns `{ id: string }` for the signed-in user or `null`.

The `saveUploadedFile` adapter from `@/lib/files` must upsert `{ userId, pathname, url }` by pathname so duplicate callbacks don't create duplicate records. Both adapters belong to your application's authentication and database code; they aren't Blob SDK exports.

```typescript
import { handleUpload, type HandleUploadBody } from '@vercel/blob/client';
import { NextResponse } from 'next/server';
import { getCurrentUser } from '@/lib/auth';
import { saveUploadedFile } from '@/lib/files';

function isAvatarPath(pathname: string, userId: string) {
  const prefix = `avatars/${encodeURIComponent(userId)}/`;
  const filename = pathname.slice(prefix.length);
  return pathname.startsWith(prefix) && filename.length > 0 &&
    !filename.includes('/') && !filename.includes('\\') &&
    filename !== '.' && filename !== '..' && pathname.length <= 950;
}

export async function POST(request: Request): Promise<NextResponse> {
  let completionFailed = false;

  try {
    const body = (await request.json()) as HandleUploadBody;
    if (!body || !['blob.generate-client-token', 'blob.upload-completed']
      .includes(body.type)) {
      throw new Error('Invalid upload request');
    }

    const jsonResponse = await handleUpload({
      body,
      request,
      onBeforeGenerateToken: async (pathname) => {
        const user = await getCurrentUser();
        if (!user) throw new Error('Not authenticated');
        if (!isAvatarPath(pathname, user.id)) {
          throw new Error('Not allowed to upload to this path');
        }

        return {
          allowedContentTypes: ['image/jpeg', 'image/png', 'image/webp'],
          maximumSizeInBytes: 5 * 1024 * 1024,
          cacheControlMaxAge: 3600,
          addRandomSuffix: true,
          tokenPayload: JSON.stringify({ userId: user.id }),
        };
      },
      onUploadCompleted: async ({ blob, tokenPayload }) => {
        const payload = JSON.parse(tokenPayload ?? '{}');
        if (!payload || typeof payload.userId !== 'string' ||
            !payload.userId || !isAvatarPath(blob.pathname, payload.userId)) {
          throw new Error('Invalid upload payload');
        }

        try {
          await saveUploadedFile({
            userId: payload.userId,
            pathname: blob.pathname,
            url: blob.url,
          });
        } catch {
          completionFailed = true;
          throw new Error('Could not save uploaded file');
        }
      },
    });

    return NextResponse.json(jsonResponse);
  } catch (error) {
    return NextResponse.json(
      { error: error instanceof Error ? error.message : 'Upload failed' },
      { status: completionFailed ? 503 : 400 },
    );
  }
}
```

The token keeps the source upload's one-hour cache lifetime and adds a random suffix to each avatar pathname. Save the returned pathname or URL instead of rebuilding it from the original filename. The completion callback uses the user ID in the signed token payload, so it can save the file without a browser session.

Return a retryable response when the database write fails. [Blob retries callback responses](https://vercel.com/docs/vercel-blob/client-upload) with status 429, 500, 502, 503, or 504 up to five times; it doesn't retry 400 responses. Keep the upsert idempotent and reconcile uploaded files whose callbacks still fail.

The route takes over the work of your RLS policy and bucket settings:

| On Supabase Storage                                                           | In the token route                                                                                            |
| ----------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------- |
| `INSERT` policy for the `authenticated` role                                  | The session check in `onBeforeGenerateToken`. Without it, anyone can upload.                                  |
| Policy that compares `storage.foldername(name)` with the user's ID            | The pathname prefix check                                                                                     |
| `allowedMimeTypes` on the bucket                                              | `allowedContentTypes`                                                                                         |
| `fileSizeLimit` on the bucket                                                 | `maximumSizeInBytes`                                                                                          |
| `upsert` and `cacheControl` upload options                                    | `allowOverwrite`, `addRandomSuffix`, and `cacheControlMaxAge`, set on the server. The browser can't set them. |
| Database trigger on `storage.objects`, or a follow-up insert from the browser | `onUploadCompleted`, which Vercel Blob calls after the upload finishes                                        |

`handleUpload()` needs the read-write token configured in step 2. For a store connected with a custom prefix, pass its read-write token as `token`. For OIDC, use [presigned client uploads](https://vercel.com/docs/vercel-blob/vercel-signed-urls) with `handleUploadPresigned()` on the server and `uploadPresigned()` in the browser.

Vercel Blob calls `onUploadCompleted` over the network, so it can't reach `localhost`. For local testing, set `VERCEL_BLOB_CALLBACK_URL` to your tunnel's public origin; the SDK appends the upload route's path. On another host, configure `callbackUrl` in `onBeforeGenerateToken` with the full public endpoint.

#### Signed upload URLs

The client-upload flow replaces `createSignedUploadUrl()` and `uploadToSignedUrl()`. Supabase signed upload URLs last 2 hours; Blob client tokens last 1 hour by default. Return `validUntil` from `onBeforeGenerateToken` to set a different lifetime.

For clients that can't run the Blob SDK, such as mobile apps or other services, use `presignUrl()` to create a [signed upload URL](https://vercel.com/docs/vercel-blob/vercel-signed-urls) for the `put` operation.

#### Large and resumable uploads

Vercel Blob has no TUS endpoint. Replace the TUS client and its 6 MB chunk size with `multipart: true` to split an upload into parallel parts and retry failed parts. This high-level call starts a new upload each time; it doesn't resume from a saved TUS URL after a page reload. If your application depends on that recovery behavior, decide how it will restart or manage resumable uploads before removing the TUS client:

```javascript
import { upload } from '@vercel/blob/client';

const blob = await upload(`videos/${user.id}/${file.name}`, file, {
  access: 'public',
  handleUploadUrl: '/api/video/upload',
  multipart: true,
  onUploadProgress: ({ percentage }) => console.log(`${percentage}%`),
});
```

Blob accepts files up to 5 TB, and Vercel recommends multipart uploads for files larger than 100 MB. On a server, pass `multipart: true` to `put()`.

### 6\. Replace public and signed URLs

Public buckets map to public blob URLs. Private buckets map to Vercel Signed URLs or to a route in your application that checks the user and streams the blob.

#### Public URLs

Supabase's `getPublicUrl()` builds a URL from the bucket and path without calling the API:

```javascript
const { data } = supabase.storage
  .from('avatars')
  .getPublicUrl('user-123/avatar.png');
console.log(data.publicUrl);
```

On Vercel, `put()` and `upload()` return the blob's `url`. Save it, or save the pathname and read the URL later with `head()`:

```javascript
import { head, put } from '@vercel/blob';

const blob = await put('avatars/user-123/avatar.png', file, {
  access: 'public',
});
console.log(blob.url);

const details = await head('avatars/user-123/avatar.png');
console.log(details.url);
```

A public blob URL has the form `https://<store-id>.public.blob.vercel-storage.com/<pathname>`. Anyone with the URL can read the blob, and search engines can index it. Pass `addRandomSuffix: true` when the URL should be hard to guess, and use a private store for anything that needs an access check.

#### Signed URLs

Supabase's `createSignedUrl()` takes a lifetime in seconds:

```javascript
const { data, error } = await supabase.storage
  .from('documents')
  .createSignedUrl('reports/2026-q1.pdf', 300);
console.log(data.signedUrl);
```

On Vercel, issue a signed token on your server, then sign each URL with it:

```javascript
import { issueSignedToken, presignUrl } from '@vercel/blob';

const pathname = 'documents/reports/2026-q1.pdf';

const token = await issueSignedToken({
  pathname,
  operations: ['get'],
  validUntil: Date.now() + 60 * 60 * 1000,
});

const { presignedUrl } = await presignUrl(token, {
  operation: 'get',
  pathname,
  access: 'private',
  validUntil: Date.now() + 300 * 1000,
});
console.log(presignedUrl);
```

`validUntil` uses an absolute timestamp in milliseconds. Convert a Supabase lifetime in seconds with `Date.now() + seconds * 1000`; the signed URL can last up to 7 days and must expire no later than its token.

`issueSignedToken()` calls the Blob API, while `presignUrl()` signs locally. Replace `createSignedUrls()` by issuing one store-wide token without `pathname`, then cache it and sign each file's URL. Keep the token secret on your server.

From a terminal, the Vercel CLI signs a URL in one command:

```bash
vercel blob presign documents/reports/2026-q1.pdf --access private --valid-for 15m
```

#### Authenticated delivery through your application

Supabase's `/storage/v1/object/authenticated/` endpoint checks the `SELECT` policy before serving a private object. On Vercel, resolve the application's file ID to an owned record, then read the blob at the pathname saved in that record.

Save the handler as `app/api/file/route.ts` and reuse your application's `getCurrentUser` helper. Implement `findFileForUser(fileId, userId)` in your database module `@/lib/files` to return an owned file record or `null`.

```typescript
import { type NextRequest, NextResponse } from 'next/server';
import { get } from '@vercel/blob';
import { getCurrentUser } from '@/lib/auth';
import { findFileForUser } from '@/lib/files';

export async function GET(request: NextRequest) {
  const user = await getCurrentUser();
  if (!user) return new NextResponse('Unauthorized', { status: 401 });

  const fileId = request.nextUrl.searchParams.get('fileId');
  if (!fileId) {
    return NextResponse.json({ error: 'Missing fileId' }, { status: 400 });
  }

  const file = await findFileForUser(fileId, user.id);
  if (!file) return new NextResponse('Not found', { status: 404 });

  const result = await get(file.pathname, { access: 'private' });
  if (result?.statusCode !== 200) {
    return new NextResponse('Not found', { status: 404 });
  }

  const contentDisposition = result.blob.contentDisposition || 'attachment';
  return new NextResponse(result.stream, {
    headers: {
      'Content-Type': result.blob.contentType,
      'Content-Disposition': contentDisposition,
      'Content-Security-Policy':
        "default-src 'none'; media-src 'self'; " +
        "style-src 'unsafe-inline'; img-src 'self'",
      'X-Content-Type-Options': 'nosniff',
      'Cache-Control': 'private, no-cache',
    },
  });
}
```

The route streams the blob, so the 4.5 MB response limit for Vercel Functions doesn't apply. It preserves Blob's download disposition and restrictive content security policy when serving user uploads from your domain. Keep the private cache policy and avoid `s-maxage`, which could let a shared cache serve one user's file to another.

For FastAPI, save the route in `main.py` and implement the equivalent async adapters in `lib.auth` and `lib.files`. Here, `get_current_user(request)` returns a dictionary with an `id` or `None`, and `find_file_for_user(file_id, user_id)` returns an owned record with a `pathname` or `None`. The response buffers the blob in memory; use `stream_blob()` with a streaming response for files larger than 4.5 MB.

```python
from fastapi import FastAPI, HTTPException, Request, Response
from vercel import blob

from lib.auth import get_current_user
from lib.files import find_file_for_user

app = FastAPI()


@app.get("/api/file")
async def get_file(request: Request, file_id: str) -> Response:
    user = await get_current_user(request)
    if user is None:
        raise HTTPException(status_code=401, detail="Unauthorized")

    file = await find_file_for_user(file_id, user["id"])
    if file is None:
        raise HTTPException(status_code=404, detail="Not found")

    try:
        result = await blob.get_blob(file["pathname"], access="private")
    except blob.BlobNotFoundError:
        raise HTTPException(status_code=404, detail="Not found") from None

    return Response(
        result.body,
        media_type=result.metadata.content_type,
        headers={
            "Content-Disposition": (
                result.metadata.content_disposition or "attachment"
            ),
            "Content-Security-Policy": (
                "default-src 'none'; media-src 'self'; "
                "style-src 'unsafe-inline'; img-src 'self'"
            ),
            "X-Content-Type-Options": "nosniff",
            "Cache-Control": "private, no-cache",
        },
    )
```

Choose between the two delivery methods for each use:

| Use                                                          | Delivery method                                               |
| ------------------------------------------------------------ | ------------------------------------------------------------- |
| Files shown inside your application to a signed-in user      | Authenticated route, which also works on your own domain      |
| Expiring links in emails or links shared with other services | Signed URL                                                    |
| Private files larger than 100 MB                             | Signed URL, which avoids sending the bytes through a Function |

#### Download links

Supabase forces a download with the `download` option or `?download=` on the URL. Each Blob result includes a `downloadUrl`, which is the blob URL with `?download=1`. To choose the downloaded file's name, serve the blob through your route and set the `Content-Disposition` header.

### 7\. Move access rules from RLS policies into your application

Vercel Blob has no policy layer. Code that holds a store's credentials can read, write, and delete every blob in the store, so keep the credentials on your server and check the user before each operation.

List the policies your buckets rely on in the Supabase SQL Editor:

```sql
select policyname, cmd, roles, qual, with_check
from pg_policies
where schemaname = 'storage' and tablename = 'objects';
```

Move each rule to the place in your application that now handles the operation:

| Supabase RLS rule                                                       | On Vercel                                                                                                                                                          |
| ----------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| `INSERT` policy for the `authenticated` role                            | Check the session in your upload route, or in `onBeforeGenerateToken` for client uploads.                                                                          |
| `(storage.foldername(name))[1]` compared with the user's ID             | Validate the upload prefix against the signed-in user's ID, using the same encoding as the stored paths. Check ownership records separately for reads and deletes. |
| `owner_id` compared with the user's ID in a `SELECT` or `DELETE` policy | Save the owner with the pathname in your database, and check it before `get()`, `presignUrl()`, or `del()`.                                                        |
| `bucket_id = 'documents'`                                               | Choose the store or pathname prefix in server code. Don't accept it from the client.                                                                               |
| `storage.extension(name)` checks                                        | Validate the pathname extension in server code before issuing an upload token or calling `put()`. Use `allowedContentTypes` as a separate MIME-type restriction.   |
| No `SELECT` policy on a public bucket                                   | Use a public store, where reads need no credentials.                                                                                                               |

Use prefixes to organize each user's files, and validate the destination in your authenticated upload route. For reads and deletes, resolve the file's ownership record before calling the Blob SDK; the prefix alone doesn't establish permission. This upload check rejects another user's destination:

```typescript
if (!pathname.startsWith(`documents/${encodeURIComponent(user.id)}/`)) {
  return new NextResponse('Forbidden', { status: 403 });
}
```

You can keep Supabase Auth and read the user from its session in these checks. Server code that already used the Supabase secret key bypassed RLS, so its own authorization checks carry over unchanged. Leave the Supabase policies in place until you delete the buckets in step 10.

### 8\. Copy existing objects into Vercel Blob

Vercel Blob cannot import a Supabase bucket directly, so the script lists live objects with your Supabase secret key, validates destination pathnames, and streams each object from a signed URL into Blob. It preserves content types and converts `max-age` to the cache lifetime used by Blob.

Install `@supabase/supabase-js` and `@vercel/blob` in the directory where you run the script. Add `SUPABASE_URL` and `SUPABASE_SECRET_KEY` to `.env.local`, then save the script as `copy-bucket.mjs`. Replace `your_bucket_name_here`, and set `ACCESS` to match the destination store:

```javascript
import { appendFile } from 'node:fs/promises';
import { createClient } from '@supabase/supabase-js';
import { put } from '@vercel/blob';

const BUCKET = 'your_bucket_name_here';
const ACCESS = 'private'; // Must match the Blob store's access.
const PREFIX = `${BUCKET}/`; // Use '' to drop the bucket name from pathnames.
const MULTIPART_THRESHOLD = 100 * 1024 * 1024;

const supabase = createClient(
  process.env.SUPABASE_URL,
  process.env.SUPABASE_SECRET_KEY,
);
const bucket = supabase.storage.from(BUCKET);

async function* walk(folder = '') {
  let offset = 0;
  while (true) {
    const { data, error } = await bucket.list(folder, {
      limit: 1000,
      offset,
      sortBy: { column: 'name', order: 'asc' },
      noncurrentVersions: 'exclude',
      deleteMarkers: 'exclude',
    });
    if (error) throw error;
    if (data.length === 0) return;

    for (const item of data) {
      if (item.name === '.emptyFolderPlaceholder') continue;
      const path = folder ? `${folder}/${item.name}` : item.name;
      if (item.id === null) yield* walk(path);
      else yield { path, metadata: item.metadata ?? {} };
    }
    offset += data.length;
  }
}

function maxAge(cacheControl) {
  const match = /max-age=(\d+)/.exec(cacheControl ?? '');
  return match ? Math.max(60, Number(match[1])) : undefined;
}

// Inspect the whole mapping before writing any destination objects.
const inventory = [];
const destinations = new Set();
for await (const item of walk()) {
  const pathname = PREFIX + item.path;
  if (pathname.includes('//') || pathname.length > 950) {
    throw new Error(`Map this source path to a valid pathname: ${item.path}`);
  }
  if (destinations.has(pathname)) {
    throw new Error(`Duplicate destination pathname: ${pathname}`);
  }
  if (!Number.isSafeInteger(item.metadata.size) || item.metadata.size < 0) {
    throw new Error(`Missing or invalid source size: ${item.path}`);
  }
  destinations.add(pathname);
  inventory.push({ ...item, pathname });
}

let copied = 0;
let failed = 0;

for (const { path, metadata, pathname } of inventory) {
  try {
    const { data, error } = await bucket.createSignedUrl(path, 3600);
    if (error) throw error;

    const response = await fetch(data.signedUrl);
    if (!response.ok || !response.body) {
      throw new Error(`Download returned HTTP ${response.status}`);
    }

    const blob = await put(pathname, response.body, {
      access: ACCESS,
      allowOverwrite: true,
      contentType: metadata.mimetype,
      cacheControlMaxAge: maxAge(metadata.cacheControl),
      multipart: metadata.size > MULTIPART_THRESHOLD,
    });

    await appendFile(
      'blob-mapping.jsonl',
      JSON.stringify({
        bucket: BUCKET,
        path,
        pathname: blob.pathname,
        sourceSize: metadata.size,
        contentType: metadata.mimetype,
        sourceCacheControl: metadata.cacheControl,
        url: blob.url,
      }) + '\n',
    );
    copied += 1;
  } catch (error) {
    failed += 1;
    console.error(`Failed to copy ${path}:`, error.message);
  }
}

console.log(`Copied ${copied} objects, ${failed} failed`);
if (failed > 0) process.exitCode = 1;
```

Finish copying before your application starts writing to the destination paths. The script uses `allowOverwrite: true`, so you can rerun it after a failure, but a rerun also replaces changes already written to Blob. It recursively visits folders and skips `.emptyFolderPlaceholder` objects. Preflight rejects duplicate destinations, missing source sizes, pathnames containing `//`, and pathnames exceeding 950 characters before uploading anything.

Resolve invalid names with an explicit, collision-free mapping before running the copy. Keep the bucket prefix when several buckets share a store. The preflight holds the inventory in memory; for a bucket too large for that, save the inventory to disk and validate it before streaming the copy.

The script preserves each object's content type and clamps any `max-age` below 60 seconds to Blob's minimum. Objects without a `max-age`, including `no-cache`, receive Blob's one-month default. Decide the fallback cache lifetime before copying those files; the manifest keeps the original cache policy for later use.

Review the [usage estimate](#estimate-usage), then run the script once for each bucket from your linked project directory:

```bash
node --env-file=.env.local copy-bucket.mjs
```

The script prints the number of copied and failed objects and exits with a failure status if any transfer fails. Each successful transfer appends its source path, destination pathname, source size, content type, cache policy, and URL to `blob-mapping.jsonl`. Reruns append another record for each copied object, so use the latest record for each bucket and source path when updating your database. Retain the manifest through verification and the rollback period.

Pass `storeId` or `token` to `put()` to target a store other than the project's default.

For large buckets, Supabase recommends downloading objects with an S3-compatible tool such as rclone. Download the bucket through Supabase's S3 endpoint, then upload the files from disk with `put()` or `vercel blob put`. Python applications can use the [large-file upload recipe](https://vercel.com/kb/guide/python-and-vercel-blob).

#### Export ownership and custom metadata

Blob has no fields for an owner, custom metadata, or the original creation time. Export those values from Postgres into a table that your application owns, using the same live-object filters as the copy inventory. Keep a separate historical export if you need metadata for previous versions or deleted objects:

```sql
select bucket_id, name, owner_id, user_metadata, created_at
from storage.objects
where bucket_id = 'your_bucket_name_here'
  and archived_at is null
  and is_delete_marker = false
  and name <> '.emptyFolderPlaceholder'
  and name not like '%/.emptyFolderPlaceholder';
```

#### Compare counts and sizes

Save this script as `count-blobs.mjs` to total the blobs under one prefix:

```javascript
import { list } from '@vercel/blob';

const PREFIX = 'your_bucket_name_here/';

let count = 0;
let bytes = 0;
let cursor;
do {
  const page = await list({ prefix: PREFIX, cursor });
  count += page.blobs.length;
  for (const blob of page.blobs) bytes += blob.size;
  cursor = page.hasMore ? page.cursor : undefined;
} while (cursor);

console.log(count, (bytes / 1048576).toFixed(2));
```

Run it with `node --env-file=.env.local count-blobs.mjs`. It prints the blob count and total size in MiB. Compare those values with the live-object query from step 1. Both inventories exclude noncurrent versions, delete markers, and the empty-folder placeholders skipped by the copy script.

Counts and totals are preliminary checks. Compare source and destination inventories by pathname and byte size, using the bucket-prefix mapping from the manifest. Investigate missing, extra, and mismatched entries, then compare content checksums for critical files or a representative sample. SDK ETags aren't interchangeable content hashes.

### 9\. Update stored URLs and paths

Update the references your database holds, based on what each column stores:

| Your database stores                   | What you change                                                                                                                                |
| -------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------- |
| Object paths, such as `reports/q1.pdf` | Keep the values if the copy kept each path. Add the bucket prefix in code or in the column if you used one.                                    |
| Public URLs on `supabase.co`           | Use the corresponding Blob URL from the manifest. If every path is unchanged, you can replace the hostname and bucket prefix in one statement. |
| Signed URLs                            | Don't migrate them. Create a new signed URL when a user requests the file.                                                                     |

If the copy preserved every source path, one statement can rewrite a column of public URLs. Replace `profiles` and `avatar_url` with your table and column, and take the store's hostname from a `url` in `blob-mapping.jsonl`. For remapped paths, update each row from its matching manifest record instead:

```sql
update profiles
set avatar_url = replace(
  avatar_url,
  'https://your_project_ref.supabase.co/storage/v1/object/public/avatars/',
  'https://your_store_id.public.blob.vercel-storage.com/avatars/'
)
where avatar_url like
  'https://your_project_ref.supabase.co/storage/v1/object/public/avatars/%';
```

Run the statement in a transaction and open a few rewritten URLs before committing. If paths were remapped or contain spaces or other encoded characters, take each URL from the latest manifest record for that bucket and source path.

Supabase doesn't redirect old object URLs to Blob. Links in sent emails, cached pages, and other sites keep working only while the objects stay in the bucket, so keep public buckets in place until requests to them stop. Also replace the Supabase hostname with the Blob hostname in your `next.config.js` `remotePatterns` and in any Content Security Policy.

### 10\. Verify and cut over

#### Validate files and application behavior

Check the copied files and the new code paths before switching traffic:

- Compare source and destination inventories by pathname and byte size using the same mapping and exclusions as the copy script. Resolve missing, extra, and mismatched files before cutover, and check content checksums for critical files or a representative sample.
  
- Open files of each content type from their Blob URLs, and check that each one displays or downloads as you expect.
  
- Test each access rule as a signed-out user, as the wrong user, and with an expired signed URL.
  
- Upload a file through each path, including a server upload, a client upload larger than 4.5 MB, and a multipart upload.
  
- Check plan limits. Hobby includes 1 GB of storage, 10,000 Simple Operations, 2,000 Advanced Operations, and 10 GB of Blob Data Transfer each month, and Vercel blocks access to the store when you exceed them.
  

#### Estimate usage

Estimate storage, Simple Operations, Advanced Operations, and Blob Data Transfer with [Vercel Blob pricing](https://vercel.com/docs/vercel-blob/usage-and-pricing). Include the initial copy, verification reads, and any repeat runs. Multipart uploads and TTLs add operations; deletes are free but still count toward operation rate limits.

Each Blob URL request counts as a CDN Request. Fast Origin Transfer applies on cache misses. Streaming private files through a Function also adds the Function's delivery and compute usage, so include the complete delivery path in your estimate.

#### Switch reads and writes

Keep Supabase authoritative until the final copy is verified. Have your storage module record uploads, replacements, metadata updates, renames, and deletes in a durable, ordered change log, and retain it until the rollback period ends. If you can't pause mutations for the final copy, replay that log and verify that the destination has caught up before switching providers.

1. Run the copy script for each bucket while your application still writes to Supabase.
   
2. Pause uploads, replacements, metadata updates, renames, and deletes. Rerun the copy, reconcile the change log, and verify pathnames and file contents. Remove stale destination objects with `del()` for source files deleted or renamed since the first copy.
   
3. Update stored URLs and paths as step 9 describes, switch the flag so reads and writes use Vercel Blob, and resume mutations.
   
4. Monitor upload errors and failed file requests after the switch.
   

#### Keep a rollback path until cleanup

Before rolling back, pause uploads, replacements, metadata updates, renames, and deletes, then wait for in-flight operations and completion callbacks to finish. Copy new and changed files back with `get()` and Supabase's `upload()`, using `useCache: false` for private blobs and `upsert: true` for replacements. Preserve content types and cache settings.

Reconcile recorded metadata changes, deletions, and renames, then verify the resulting paths, sizes, and access rules. Restore stored URLs and switch reads and writes back to Supabase only after verification, then resume mutations. Keep the buckets, RLS policies, and keys until the rollback period ends.

#### Remove the retired bucket

After the rollback period, empty the migrated bucket and confirm that its objects, versions, and delete markers are gone before deleting the bucket itself. `emptyBucket()` runs in the background and supports up to 200,000 objects, including retained versions and delete markers.

For a larger versioned bucket:

1. Inventory every version and delete marker with `listV2()`, setting both `noncurrentVersions` and `deleteMarkers` to `'include'`. Follow every page and finish the inventory before removing entries.
   
2. Pass `{ path, versionId }` entries to `remove()` in batches of up to 1,000. Pathname-only deletes retain version history.
   
3. Confirm the bucket is empty before calling `deleteBucket()`.
   

Follow [Supabase's versioned-bucket cleanup rules](https://supabase.com/docs/guides/storage/buckets/object-versioning#empty-or-delete-a-bucket). Deleting exact versions is permanent. Don't delete rows from `storage.objects` with SQL, because that leaves the stored files behind.

Once the retired buckets are gone, remove what only the migrated files used:

- Remove unused Supabase Storage calls and the provider flag.
  
- Drop the RLS policies that applied to the deleted buckets, and revoke any S3 access keys.
  
- Keep the Supabase secret key if your application still uses it for the database or Auth.
  
- Delete `blob-mapping.jsonl` and the `migration-check/hello.txt` blob from step 4.
  

## What doesn't map from Supabase Storage

These features need a different design on Vercel. Run the examples from the linked project directory with the latest Vercel CLI.

### Image transformations

Vercel Blob serves each blob as stored, and has no equivalent to the `transform` option or `/render/image/` URLs. Choose a replacement based on where the image is resized:

| On Supabase Storage                                                     | On Vercel                                                                                                                    |
| ----------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------- |
| `transform` on `getPublicUrl()` for a public bucket                     | `next/image`, which resizes public blob URLs through [Vercel Image Optimization](https://vercel.com/docs/image-optimization) |
| `transform` on `createSignedUrl()` or `download()` for a private bucket | `putImage()` at upload, then your authenticated route or a signed URL for the stored size                                    |
| Supabase's custom image loader for Next.js                              | The default Next.js loader with a `remotePatterns` entry for your store                                                      |
| One stored size that every page uses                                    | `putImage()`, which resizes at upload and stores only the result                                                             |

This Supabase call returns a URL that resizes the image on request:

```javascript
const { data } = supabase.storage
  .from('avatars')
  .getPublicUrl('user-123/avatar.png', {
    transform: { width: 200, height: 200 },
  });
```

On Vercel, allow your public store's hostname in `next.config.js`. Replace `your_store_id_here` with the store ID from the blob URL. The `URL` object syntax below requires Next.js 15.3.0 or later:

```javascript
/** @type {import('next').NextConfig} */
const nextConfig = {
  images: {
    remotePatterns: [
      new URL('https://your_store_id_here.public.blob.vercel-storage.com/**'),
    ],
  },
};

module.exports = nextConfig;
```

Then render the stored blob URL with `next/image`, and remove any Supabase image loader from your configuration:

```tsx
import Image from 'next/image';

export function Avatar({ url }: { url: string }) {
  return <Image src={url} alt="Profile photo" width={200} height={200} />;
}
```

To store one optimized size instead, resize the image when you upload it. `putImage()` requires OIDC credentials and rejects read-write tokens:

```javascript
import { putImage } from '@vercel/blob';

const blob = await putImage('avatars/user-123/avatar.webp', file, {
  access: 'public',
  optimizeImage: { width: 400, format: 'webp' },
});
console.log(blob.url);
```

### S3 protocol access

Vercel Blob has no S3-compatible API. Replace clients and tools that connect to Supabase's S3 endpoint:

| S3 client on Supabase Storage                | On Vercel Blob                                                                                                   |
| -------------------------------------------- | ---------------------------------------------------------------------------------------------------------------- |
| `@aws-sdk/client-s3` or boto3 calls          | `@vercel/blob`, or the `vercel` Python package                                                                   |
| AWS CLI or rclone commands in scripts and CI | `vercel blob put`, `list`, `get`, `copy`, and `delete`, authenticated with `--rw-token` outside a linked project |
| S3 multipart uploads                         | `multipart: true` on `put()` or `upload()`                                                                       |
| SigV4 presigned URLs                         | Vercel Signed URLs from `presignUrl()`                                                                           |
| S3 access keys                               | OIDC, or a read-write token                                                                                      |

If a workload needs the S3 API itself, keep it on Supabase Storage or connect [Amazon S3 from the Vercel Marketplace](https://vercel.com/changelog/amazon-s3-joins-the-vercel-marketplace).

### Object versioning and lifecycle rules

Vercel Blob keeps one version of each pathname, and an overwrite replaces it. To keep earlier versions, write each one to a new pathname with `addRandomSuffix: true` or a version in the path, and record the current pathname in your database. When several writers update one blob, pass the last ETag as `ifMatch` so a stale write fails with `BlobPreconditionFailedError`.

Supabase lifecycle policies expire noncurrent versions. On Blob, set `ttlDays` to delete a blob automatically between 1 and 730 days after upload:

```javascript
import { put } from '@vercel/blob';

await put('exports/report.csv', csv, {
  access: 'private',
  ttlDays: 7,
});
```

Call `setTtl()` to add or clear the lifetime on an existing blob. Pass `ttlDays` again when you copy, rename, or overwrite a blob, because those operations drop it.

### Ownership, custom metadata, and database triggers

Supabase stores each object as a row in `storage.objects`, so applications join against it, read `owner_id` and `user_metadata`, and attach triggers to it. Vercel Blob has no table to query. Create a table that your application owns and write to it when an upload finishes:

```sql
create table files (
  id uuid primary key default gen_random_uuid(),
  pathname text not null unique,
  url text not null,
  owner_id text,
  metadata jsonb,
  created_at timestamptz not null default now()
);
```

Upsert a row by pathname after `put()` returns or in `onUploadCompleted` for client uploads. The upsert must be idempotent because Blob can deliver a completion callback more than once; return 503 when persistence fails so Blob can retry it. This application code replaces triggers on `storage.objects`, and queries against your table replace queries against the storage table. If it stays in Supabase Postgres, you can protect it with RLS like any other table.

### Other SDK features

These Supabase Storage features have a different interface on Vercel, or none:

| Supabase Storage feature                                 | On Vercel Blob                                                                                                             |
| -------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------- |
| `createBucket()`, `updateBucket()`, and `deleteBucket()` | `vercel blob create-store` and `vercel blob delete-store`, or the dashboard. A store's access can't change after creation. |
| `listBuckets()` and `getBucket()`                        | `vercel blob list-stores` and `vercel blob get-store`                                                                      |
| `emptyBucket()`                                          | `vercel blob empty-store`, or `list()` and `del()` in batches                                                              |
| `createSignedUrls()`                                     | One signed token for the whole store, then `presignUrl()` for each pathname                                                |
| `purgeCache()` and `purgeBucketCache()`                  | No purge call. An overwrite or delete clears from the CDN within 60 seconds.                                               |
| `metadata` option on `upload()`                          | No equivalent. Save the values in your database.                                                                           |
| Publishable-key access from a browser or mobile client   | No equivalent. Send each operation through your backend, or issue a client token or signed URL.                            |
| Analytics and vector buckets                             | No equivalent. Keep these buckets on Supabase.                                                                             |
| `supabase storage` CLI commands                          | [`vercel blob`](https://vercel.com/docs/cli/blob) [commands](https://vercel.com/docs/cli/blob)                             |

## Troubleshooting

Use these checks to diagnose changes in behavior after migration.

| What you observe                                                         | What to check                                                                                                                                                                                            |
| ------------------------------------------------------------------------ | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Authentication fails locally, or the SDK reports missing credentials     | The store must be connected to the Development environment. Add it from the store's **Projects** tab, then run `vercel env pull` again.                                                                  |
| A call reaches the wrong store in a project that uses two stores         | The SDK reads only the unprefixed variables. Pass the second store's `storeId` to each call, and pass its read-write token as `token` to `handleUpload()`.                                               |
| A call fails with an access error                                        | The `access` option must match the store. A store created as private can't accept `access: 'public'`, and access can't change after creation.                                                            |
| `put()` throws because the blob already exists                           | Blob rejects an existing pathname by default. Pass `allowOverwrite: true`, or `addRandomSuffix: true` for a unique pathname.                                                                             |
| An upload through your route fails with `413 FUNCTION_PAYLOAD_TOO_LARGE` | Vercel Functions have a 4.5 MB request body limit. Use a client upload to send file bytes directly from the browser to Blob.                                                                             |
| `handleUpload()` fails with a credentials error                          | `handleUpload()` requires a read-write token and doesn't accept OIDC. Add the token to the connection, or switch to `handleUploadPresigned()`.                                                           |
| `onUploadCompleted` never runs during local development                  | Vercel Blob can't reach `localhost`. Use a tunnel and set `VERCEL_BLOB_CALLBACK_URL`.                                                                                                                    |
| A private blob URL fails in a browser or an `<img>` tag                  | Private blob URLs need store credentials or a signature. Serve the blob through your route, or create a signed URL.                                                                                      |
| A signed URL expires almost immediately                                  | `validUntil` is a timestamp in milliseconds. Pass `Date.now() + seconds * 1000`, not the lifetime in seconds.                                                                                            |
| `presignUrl()` fails for a pathname                                      | The pathname must fall inside the signed token's scope. Issue the token without `pathname` to cover the whole store.                                                                                     |
| An updated file still shows its old content                              | Write changed files to a new pathname to give them a new URL. For an immediate private server read, pass `useCache: false` to `get()`. Existing browser copies follow their cache lifetime.              |
| A moved or copied file has a different content type or cache lifetime    | `rename()` and `copy()` don't carry over those settings. Pass `contentType` and `cacheControlMaxAge` again.                                                                                              |
| A file downloads instead of opening in the browser                       | Blob displays images, video, audio, PDF, plain text, JSON, and `text/xml` inline and serves other types, including HTML, as downloads.                                                                   |
| `next/image` returns an error for a blob URL                             | Add the store's hostname to `remotePatterns`. `next/image` loads direct blob URLs from public stores only.                                                                                               |
| `list()` returns blobs in a different order than Supabase did            | Blob lists in pathname order and has no `sortBy` option. Sort in your application, or put a date in the pathname.                                                                                        |
| `list()` returns nested files where Supabase returned folders            | Blob lists recursively by default. Pass `mode: 'folded'` and read `folders`.                                                                                                                             |
| The copy script fails on some objects with a pathname error              | The preflight rejects pathnames containing `//` or exceeding 950 characters. Create and validate an explicit, collision-free pathname mapping before copying, and preserve it when updating stored URLs. |
| Calls fail with `BlobServiceRateLimited`                                 | Operations are limited per minute for each plan. Wait for the error's `retryAfter` value, and reduce concurrency in batch jobs.                                                                          |
| Calls fail with `BlobStoreSuspendedError` on Hobby                       | The store exceeded the plan's included usage. See [blocked stores](https://vercel.com/docs/vercel-blob/blocked-store).                                                                                   |
| A Python upload from a stream or an open file fails                      | Streaming bodies need `content_length` in `put_blob()` and in each `upload_part()`. The async API rejects synchronous file objects, so read the file into bytes or import `sync` from `vercel.blob`.     |

## What to build with Vercel Blob

### User uploads from the browser

Profile photos and attachments can go directly from the browser to Vercel Blob without passing through your server. Use `upload()` with a token route that checks the user’s permissions and limits the file’s type and size. Save the returned pathname in an idempotent completion callback so the application can associate each file with its owner.

Start from the [Vercel Blob Next.js Starter](https://vercel.com/templates/next.js/blob-starter), or [add private uploads to a Next.js application](https://vercel.com/kb/guide/vercel-blob-nextjs). Choose an [upload method that fits the file size](https://vercel.com/kb/guide/how-to-upload-and-store-files-with-vercel) for your application.

### Private documents with authenticated downloads

Keep invoices, contracts, and receipts in a private store. Your delivery route must check permission for the requested file before reading it; a user’s pathname prefix organizes files but does not enforce access. For temporary sharing, issue a signed URL after the same permission check and treat it as a bearer link until it expires.

Build a [private file upload application](https://vercel.com/kb/prompts/build-private-file-upload-app) from an agent prompt, or [store and serve per-user files from Python](https://vercel.com/kb/guide/python-and-vercel-blob).

### AI applications and agent files

Store chat attachments, generated media, and agent-written documents under a user or run prefix, then keep their pathnames with the conversation records. Private storage can also hold agent memory between sessions. When a model needs a URL for private input media, use a signed URL with enough lifetime for the model to fetch it instead of making the whole store public.

Deploy the [Chatbot template](https://vercel.com/templates/next.js/chatbot) for file attachments or the [eve Memory Agent](https://vercel.com/templates/eve/eve-memory-agent) for persistent memory. The [memory-provider comparison](https://vercel.com/kb/guide/choose-an-eve-memory-provider) explains the storage choice, and the [Slack file-management bot](https://vercel.com/kb/guide/slack-bot-vercel-blob) connects file operations to an agent’s tools.

### Images, video, and large media

Public stores serve images and video by URL. Use `multipart: true` for large uploads and report progress with `onUploadProgress`; range requests let a video player seek without downloading the whole file. Blobs over 512 MB remain accessible but aren’t cached by Vercel’s CDN, so plan for origin reads.

Deploy an [image gallery](https://vercel.com/templates/next.js/image-gallery-starter), build [image hosting with Nuxt](https://vercel.com/kb/guide/vercel-blob-nuxt-imgur-clone), or follow the Next.js guidance on [serving video](https://nextjs.org/docs/app/guides/videos). For processing before delivery, [transform uploads in Vercel Sandbox](https://vercel.com/kb/guide/user-uploaded-files-vercel-sandbox-and-blob) and save the results in Blob.

### Generated reports and temporary exports

Workflows and scheduled jobs can write reports or rendered media that remain available after the job ends. Use a job-specific pathname and an explicit overwrite policy for retries, then deliver the finished file through the application’s access checks. Temporary exports can use `ttlDays`, which deletes files on a daily schedule rather than at an exact time of day.

Run a [research agent that saves its report to Blob](https://vercel.com/kb/guide/how-to-run-a-multi-step-research-agent-on-vercel), or render video with [Remotion on Vercel](https://vercel.com/templates/next.js/remotion-on-vercel). If a job replaces an export, check the [TTL behavior and overwrite rules](https://vercel.com/changelog/vercel-blob-now-supports-ttls-for-automatic-deletion).

## Next steps

- Choose the appropriate delivery behavior for [private](https://vercel.com/docs/vercel-blob/private-storage) and [public](https://vercel.com/docs/vercel-blob/public-storage) files
  
- Use [client uploads](https://vercel.com/docs/vercel-blob/client-upload) for browser uploads or [signed URLs](https://vercel.com/docs/vercel-blob/vercel-signed-urls) for temporary access
  
- Look up methods in the [JavaScript](https://vercel.com/docs/vercel-blob/using-blob-sdk) and [Python](https://vercel.com/docs/vercel-blob/python-sdk-reference) SDK references
  
- Manage stores and files with the [Blob CLI](https://vercel.com/docs/cli/blob)
  
- Review [authentication and firewall controls](https://vercel.com/docs/vercel-blob/security), then estimate [usage and costs](https://vercel.com/docs/vercel-blob/usage-and-pricing)
  

## Related resources

- Plan application storage with the [complete Blob guide](https://vercel.com/kb/guide/vercel-blob)
  
- Use [server uploads](https://vercel.com/docs/vercel-blob/server-upload) for files generated or received by your backend
  
- Supply input images for [AI Gateway video generation](https://vercel.com/docs/ai-gateway/modalities/video-generation/image-to-video)
  
- See how [Superset stores artifacts from agents and users](https://vercel.com/customers/how-superset-built-the-ide-for-ai-agents-on-vercel)
  
- Build a [research workspace that saves its artifacts](https://vercel.com/kb/guide/run-research-workspace-vercel)
  
- Adapt the [Blob backup examples](https://vercel.com/docs/vercel-blob/examples) for scheduled exports
  

## Frequently asked questions

### Can I move Supabase Storage objects to Vercel Blob directly?

No. Vercel Blob can't import from a Supabase bucket. Copy each object through a script that downloads it from Supabase and uploads it with `put()`, as step 8 shows.

### Can I keep my Supabase database and Auth with Vercel Blob?

Yes. Vercel Blob replaces only Supabase Storage. Keep the Supabase client for database queries and Auth, and use the Auth session to authorize Blob operations in your routes.

### Can I use Vercel Blob without changing hosts?

Yes. The Vercel Blob SDKs work from any backend with a read-write token in `BLOB_READ_WRITE_TOKEN`. Applications deployed on Vercel authenticate with the project's OIDC token instead.

### Do I need separate Blob stores for public and private buckets?

Yes. Access applies to a whole store and can't change after creation, so create a public store for public buckets and a private store for private buckets. Buckets with the same access can share one store under different pathname prefixes.

### Does Vercel Blob support signed URLs like Supabase Storage?

Yes. `issueSignedToken()` and `presignUrl()` create URLs that expire after up to 7 days. The Python SDK doesn't sign URLs, so use the JavaScript SDK or `vercel blob presign`.

### How do I replace Supabase RLS policies on Vercel Blob?

Move each RLS rule into the server code that handles the corresponding operation. Check both the signed-in user and the requested file's ownership before reading, deleting, or signing a URL, and authorize client uploads in `onBeforeGenerateToken`. Filename-extension checks and MIME-type limits remain separate rules.

### Can Vercel Blob transform images like Supabase Storage?

Not at request time. Resize public blobs with `next/image` and Vercel Image Optimization, or resize once at upload with `putImage()`.

### Can I migrate from Supabase Storage and keep using Python?

Yes. The `vercel` package supports Python 3.11 or later with asynchronous and synchronous APIs. Some names differ from Supabase's Python client, for example `put_blob()` instead of `upload()`. Client uploads, signed URLs, and renames aren't in the Python SDK.

### What is the largest file I can store in Vercel Blob?

5 TB. Vercel Functions have a 4.5 MB request body limit, so larger file transfers should go directly from the browser to Blob with a client upload. Use multipart uploads for files above 100 MB.

### Do old Supabase Storage URLs redirect to Vercel Blob?

No. Update the URLs your database stores, and keep each public bucket until requests to its old URLs stop.

### Does Vercel Blob have an S3-compatible API?

No. Use the Blob SDKs, the Vercel CLI, or signed URLs. For workloads that need the S3 API, connect Amazon S3 from the Vercel Marketplace.

## Related Resources

- [The Complete Guide to Vercel Blob](/kb/guide/vercel-blob): Vercel Blob stores and serves files of any size through Vercel's global network. Learn how Blob works, what it costs, and how to upload files from your server or directly from the browser.
- [Build with Vercel Blob on Next.js](/kb/guide/vercel-blob-nextjs): Deploy the Vercel Blob Next.js Starter and learn how client uploads store images securely in a private Blob store.
- [Store and serve files from Python with Vercel Blob](/kb/guide/python-and-vercel-blob): Upload, list, stream, and protect files from a Python app with Vercel Blob, including private per-user storage in FastAPI.
- [Build a private file upload app with Vercel Blob](/kb/prompts/build-private-file-upload-app): Build an owner-only file library with private Vercel Blob storage, authenticated downloads, and checks for cross-user access.
- [Use private Vercel Blob storage](https://vercel.com/docs/vercel-blob/private-storage): Serve private files through an authenticated application route.

## More Vercel Blob guides

- [Migrate from Upstash Blob to Vercel Blob](/kb/guide/migrate-from-upstash-blob-to-vercel-blob): Migrate from Upstash Blob to Vercel Blob in TypeScript or Python, including Blob stores, browser uploads, private files, signed URLs, object copies, and a staged cutover.
- [Migrate from Cloudflare R2 to Vercel Blob](/kb/guide/migrate-from-cloudflare-r2-to-vercel-blob): Migrate from Cloudflare R2 to Vercel Blob, including S3 API and Workers binding calls, public and private access, signed URLs, client uploads, copying existing objects, and a staged cutover.
- [Migrate from Netlify Blobs to Vercel Blob](/kb/guide/migrate-from-netlify-blobs-to-vercel-blob): Migrate from Netlify Blobs to Vercel Blob, including stores, private and public access, metadata, conditional writes, a copy script, and a staged cutover.

## Reference Architecture

Choose a stack and work through the decisions behind it, with curated documentation, guides, templates, and courses to help you build.

- [Agent stack](/kb/architecture/agents): Build and operate agents with models, tools, and durable workflows.
- [Web applications](/kb/architecture/web): Choose rendering, data, authentication, and caching approaches.
- [Backends](/kb/architecture/backends): Choose a runtime, connect services, and run background work.

[Browse all stacks](/kb/architecture)

## Build with prompts

Build an app, extend an agent, or improve your project with ready-to-use prompts for your coding agent.

[Browse the prompt library](/kb/prompts) · [Read the Markdown index](/kb/prompts.md)

## Search guides from your terminal

Search the Knowledge Base and read guides as Markdown with the Vercel CLI. No login required.

```bash
# Find guides by keyword
npx vercel@latest kb search "rewrites and redirects"
npx vercel@latest kb search "AI SDK streaming"

# Show the latest guides
npx vercel@latest kb

# Print a guide as Markdown, by slug or URL
npx vercel@latest kb inspect <guide>
```
