Skip to main content
Digital products skip the warehouse: no stock to reserve, no address to collect, no carrier to call. That behavior comes from the product’s delivery profile — assign a digital profile and checkout, fulfillment and the customer experience adapt. This guide walks through selling an uploaded file end to end. For the concepts behind each piece — assets, links, allowances, providers — see Products → Digital products. This page is the practical walkthrough.

What you will build

  • A digital variant — one whose delivery profile requires no shipping address, so a fully digital cart completes checkout without a delivery step.
  • A downloadable file on it — uploaded to private storage and attached as a digital asset.
  • Automatic delivery — a download link granted on order placement, and an email that sends it.
  • Mixed carts — physical and digital items in one order, handled without extra work.

1. Make the product digital

A variant is digital when its delivery profile is a digital one. A store ships with a built-in Digital delivery profile; assign it to the product and the product’s variants stop asking for a shipping address.
A product’s delivery profile is auto-assigned when it is created — from its product type’s template, or the store default. You only set it explicitly to change it. Selling from the dashboard, this is the Shipping profile field on the product page.

2. Attach the file

Upload the file to private storage and attach it to the variant as a digital asset. Private storage matters: a digital file is only ever served through a short-lived signed link, so the Admin API refuses a blob that landed on the public bucket.
Admin SDK
Leave authorized_clicks and authorized_days off to inherit the store’s download limits, or set them per file to mix evergreen downloads with time-limited ones. See the allowance for how the limits resolve.

On a marketplace

A seller attaches files to their own products the same way, from the Digital files card on the product page in their seller panel, or through the Seller API. They can upload, replace and delete files and set per-file download limits. A product belonging to another seller answers 404. Sellers upload files only. A custom digital asset provider is your own integration, so sellers cannot pick one. A file you attached with a provider still appears on the seller’s product, without its provider settings, and the seller cannot replace it. Seller uploads are off until you turn them on, under Settings → Marketplace → Seller files, because a file a buyer downloads under your name is one you vouch for. Three settings shape them:
  • Let sellers upload digital files (seller_digital_assets_enabled). Off, the seller panel shows the files you attached and nothing else.
  • Accepted file types for sellers (seller_digital_asset_content_types). Checked against the file’s own signature where it has one, not its name, so a renamed executable does not pass as a PDF; a format with no signature, such as plain text, is taken at the type the upload declared. An entry names one type, or a whole family with * as the subtype (audio/*). The default covers documents, ebooks, archives, audio, video, images and plain text; add application/octet-stream only if your sellers trade in a format nothing recognises, since it admits anything unknown. Your own uploads are never restricted.
  • Review file changes on products already on sale (review_seller_digital_asset_changes, on by default). A seller adding or replacing a file on an approved product sends it back to review and off sale until you approve it again; the new submission says why. Changing download limits does not. The setting does nothing when seller products publish automatically.
None of this inspects a file for malware. The accepted type list is a policy, and ZIP is on it. To scan what sellers upload, register a handler on the digital_assets.create.validate hook, which fires with the file already in storage and can refuse it, or on after_create to queue a slower scan. The same hooks see the operator’s uploads and files nested in a product write. See Workflows → hooks.
You can attach a file to a physical variant too — a manual or warranty PDF that ships alongside the goods. Carrying files and being digital are independent: the physical variant still needs an address, and it also grants a download link.

3. Let the order deliver itself

There is no step three to configure. When the order is placed, the digital fulfillment provider runs automatically — it needs no address and no manual dispatch — and grants the buyer one download link per file, per purchased unit. Spree::DigitalAssetMailer then emails the links as a message of its own, so it survives a replaced order-confirmation template and can be re-sent from the order page. The customer downloads by following the link’s token; each download is counted against the allowance and publishes a digital_link.downloaded event. If they exhaust their downloads or you replace the file mid-sale, an admin restores access by resetting the link from the order page.
To deliver something other than an uploaded file — a license key minted on demand, an entitlement from your own system — the delivery step is pluggable. See Build a Custom Digital Asset Provider.

4. Mixed carts work on their own

A cart with both physical and digital items needs nothing special. Spree splits the order into separate fulfillments per delivery profile, so the physical items collect an address and ship while the digital items skip straight to granting links. The delivery step only appears when at least one item actually needs shipping; an all-digital cart never sees it.