Home

Create signed URLs

Creates multiple signed URLs. Use a signed URL to share a file for a fixed amount of time.

  • RLS policy permissions required:
    • buckets table permissions: none
    • objects table permissions: select
  • Refer to the Storage guide on how access control works
Parameters
  • paths
    REQUIRED
    string[]

    The file paths to be downloaded, including the current file names. For example `['folder/image.png', 'folder2/image2.png']`.

  • expiresIn
    REQUIRED
    number

    The number of seconds until the signed URLs expire. For example, `60` for URLs which are valid for one minute.

  • options
    Optional
    object

const { data, error } = await supabase
  .storage
  .from('avatars')
  .createSignedUrls(['folder/avatar1.png', 'folder/avatar2.png'], 60)
Need some help?

Not to worry, our specialist engineers are here to help. Submit a support ticket through the Dashboard.