Skip to content
Back to Blog
Technical10 min read•
Chris MaskChris Mask
•Published

Building Marketplace Payments with Stripe Connect: Complete Implementation Guide

A technical guide to Stripe Connect for marketplaces, covering account types, seller onboarding, payment flows, webhooks, refunds, and disputes.

Who Is This For?

This guide is specifically designed for:

Startup Stage:

MVP & Launch

Building your minimum viable product and preparing for market launch.

Best For Role:

Developers

Technical implementation guides and code examples for developers.

Expected Impact:

Strategic

Medium-term initiatives that build competitive advantages.

Platform: Platform Agnostic
Reading Level: Advanced

Short answer: Stripe Connect handles KYC, seller payouts and much of the compliance work, but your marketplace still has to choose how sellers are onboarded, how money flows from buyer to seller, and how refunds and disputes are handled. Get those three decisions right before you write code, because they are hard to change once you have live sellers and money in flight.

A marketplace payment integration needs more than a checkout. This guide covers Stripe Connect account types, seller onboarding, payment flows, and the operational work around refunds and disputes.

Here's what nobody tells you: Stripe Connect is simultaneously the easiest and hardest part of building a marketplace. For the complete picture of what you're building, start with what it actually costs to build a marketplace.

Easy because Stripe handles the complex parts: compliance, KYC, bank account verification, international payments, and fraud detection.

Hard because one wrong implementation decision locks you into patterns that become impossible to change when you have 10,000 sellers and millions in monthly GMV.

This guide walks through each decision point, the common pitfalls, and the tradeoffs we weigh when we build marketplace payment flows.

Connected Account Types: Standard, Express and Custom

Before you write code, decide who owns the seller's Stripe account, who sees which dashboard, and who carries the risk if a seller cannot cover a refund or dispute. Stripe's older labels name three common set-ups.

Note (updated November 2026): Stripe now describes accounts through controller properties (who pays fees, who is liable for losses, which dashboard the seller sees, who collects onboarding information) rather than one type. Standard, Express and Custom still describe the common combinations, and the type parameter still works. Check the current Stripe Connect documentation before you build.

StandardExpressCustom
Seller dashboardFull Stripe DashboardLight Stripe-hosted Express dashboardNone (you build it)
OnboardingStripe-hostedStripe-hosted, with your brandingYou build it, or use embedded components
Who carries payment lossesThe seller (and Stripe)Your platformYour platform
Seller relationship with StripeDirectThrough your platformThrough your platform
Typical useSoftware platforms where sellers already run a businessMarketplaces that pay individuals and small businessesFully branded payment experiences

Our take: Express, or the equivalent controller settings, is the usual fit for a marketplace that pays many small sellers. Standard suits a platform whose sellers are established businesses that want their own Stripe dashboard. Choose Custom only with a payments team and a compliance plan, because you take on the onboarding experience and the risk.

Seller Onboarding Flow

Create the connected account, send the seller to a Stripe-hosted onboarding link, then trust the webhook, not the redirect, to tell you when they are ready.

// 1. Create a connected account (Express settings)
const account = await stripe.accounts.create({
  type: "express",
  country: seller.country, // fixed after creation
  email: seller.email,
  capabilities: {
    card_payments: { requested: true },
    transfers: { requested: true },
  },
  metadata: { seller_id: seller.id },
});

await db.seller.update({
  where: { id: seller.id },
  data: { stripeAccountId: account.id },
});

// 2. Create a single-use onboarding link
const accountLink = await stripe.accountLinks.create({
  account: account.id,
  refresh_url: `${APP_URL}/seller/onboarding?refresh=true`,
  return_url: `${APP_URL}/seller/onboarding/return`,
  type: "account_onboarding",
});

// Redirect the seller to accountLink.url

Three details that cause bugs:

  • Links expire. An account link is single use. If the seller lands on refresh_url, create a new link.
  • The return page proves nothing. A seller can reach return_url without finishing. Read charges_enabled, payouts_enabled and requirements from the account, which account.updated webhooks keep current.
  • Country is fixed. You cannot change a connected account's country after creation, so ask for it before you create the account.

Payment Flows: Which Charge Type to Use

Stripe Connect has three charge types. They differ in where the charge lives, who appears on the buyer's statement, who owes Stripe fees and chargebacks, and when the seller gets paid. See Stripe's charge types guide for the full comparison.

At a glance:

Charge typeWho is the merchantWho handles refunds and disputesBest for
Destination chargeYour platformYouMost marketplaces
Direct chargeThe sellerThe sellerSoftware-style platforms where sellers own the customer
Separate charges and transfersYour platformYouCases where you choose payout timing or split one payment across sellers

Destination charge: the usual marketplace default

Diagram: a buyer pays $100, your platform keeps a fee, and the provider receives the rest

The charge is created on your platform account. Stripe moves the seller's share to the connected account as part of the same payment, and your fee stays on the platform.

// Buyer pays $100, platform keeps $10, seller receives $90
const paymentIntent = await stripe.paymentIntents.create({
  amount: 10000,
  currency: "usd",
  application_fee_amount: 1000,
  transfer_data: { destination: seller.stripeAccountId },
  metadata: { order_id: order.id },
});

Your platform is responsible for refunds and chargebacks on these payments. The transfer to the seller happens automatically when the payment succeeds, so you cannot use this pattern to hold money until a job is done.

Direct charge: the seller is the merchant

The charge is created on the seller's own account, so the seller appears as the merchant and carries refund and dispute liability. This fits software platforms more than marketplaces. You make the call as the connected account:

const paymentIntent = await stripe.paymentIntents.create(
  {
    amount: 10000,
    currency: "usd",
    application_fee_amount: 1000,
  },
  { stripeAccount: seller.stripeAccountId },
);

Separate charges and transfers: when payout timing is yours

Charge the buyer on the platform, then create transfers later, in parts, or to several sellers. Use it for milestone payments, one order split between several sellers, or payout only after delivery.

// 1. Charge the buyer on the platform account
const paymentIntent = await stripe.paymentIntents.create({
  amount: 10000,
  currency: "usd",
  transfer_group: `ORDER_${order.id}`,
});

// 2. Later, after the buyer confirms delivery
const transfer = await stripe.transfers.create({
  amount: 9000,
  currency: "usd",
  destination: seller.stripeAccountId,
  source_transaction: chargeId, // the charge from step 1
  transfer_group: `ORDER_${order.id}`,
});

Your platform holds the funds in between, carries the liability, and must track the state of every order. Holding buyer money can also bring licensing duties in some countries, so take legal advice and read Stripe's rules on timing before you promise "escrow" to users.

Our recommendation: Start with destination charges. Move to separate charges and transfers only when your business needs delayed or split payouts.

Refunds and Disputes

Decide in advance who absorbs the platform fee when you refund. Then let Stripe reverse the transfer for you.

// Full refund of a destination charge, taking money back from the seller
await stripe.refunds.create({
  payment_intent: order.paymentIntentId,
  reverse_transfer: true,
  refund_application_fee: true, // return your fee too; omit to keep it
});

// Partial refund of $40, with the transfer reversed in proportion
await stripe.refunds.create({
  payment_intent: order.paymentIntentId,
  amount: 4000,
  reverse_transfer: true,
});

For separate charges and transfers, refund the charge and reverse the matching transfer yourself with stripe.transfers.createReversal(transferId, { amount }).

For disputes, the charge.dispute.created webhook starts your process. Mark the order as disputed, tell the seller, and collect evidence. Stripe shows the deadline in dispute.evidence_details.due_by, so read it instead of assuming a fixed number of days. Evidence fields such as receipt and customer_signature take uploaded file IDs, not URLs, so upload the files with the Files API first. Submit with stripe.disputes.update(dispute.id, { evidence }).

Webhooks

Treat webhooks as the source of truth for payment and account state.

// app/api/webhooks/stripe/route.ts
import Stripe from "stripe";

const stripe = new Stripe(process.env.STRIPE_SECRET_KEY!);

export async function POST(request: Request) {
  const body = await request.text(); // raw body, needed for the signature
  const signature = request.headers.get("stripe-signature")!;

  let event: Stripe.Event;
  try {
    event = stripe.webhooks.constructEvent(
      body,
      signature,
      process.env.STRIPE_WEBHOOK_SECRET!,
    );
  } catch {
    return Response.json({ error: "Invalid signature" }, { status: 400 });
  }

  switch (event.type) {
    case "payment_intent.succeeded":
    case "payment_intent.payment_failed":
    case "charge.dispute.created":
      // Platform events: update the order
      break;
    case "account.updated":
    case "payout.paid":
    case "payout.failed":
      // Connect events: event.account is the connected account ID
      break;
  }

  return Response.json({ received: true });
}

Notes:

  • Events from connected accounts, such as account.updated and payouts, arrive on a webhook endpoint that you register for Connect events. Platform events use a separate account endpoint. Create both.
  • Verify every signature, and make handlers safe to run twice. Stripe retries failed deliveries and can send an event more than once.
  • Return 200 quickly and do slow work in a queue.

Testing in Test Mode

Use test mode and Stripe's test cards for every flow before launch. Never send real card numbers through your own server.

CaseTest card
Successful payment4242 4242 4242 4242
Card declined4000 0000 0000 0002
Insufficient funds4000 0000 0000 9995
Creates a dispute4000 0000 0000 0259

Test the sad paths as carefully as the happy path: a seller who abandons onboarding, a failed payout, a refund after the transfer, and a dispute.

What to Decide in Week One

Account type, charge type and payout timing are hard to change once sellers are live. Settle these three before you build:

  1. Account set-up: Express-style for most marketplaces.
  2. Charge type: destination charges, unless you need delayed or split payouts.
  3. Money rules: who pays the fee on a refund, and when sellers get paid.

Then wire up webhooks and test every path in test mode. For the wider picture, see our payment processing implementation guide and marketplace trust and safety guide.

Stripe Connect FAQ

Which Stripe Connect account type should a marketplace start with?

Most marketplaces that pay many small sellers use Express-style accounts: Stripe handles onboarding and identity checks, and sellers get a light dashboard. Standard fits sellers who already run a business and want their own Stripe dashboard. Stripe now configures accounts through controller properties, so check the current Connect docs for the exact settings.

Can Stripe Connect hold funds until a job or delivery is complete?

Yes, with separate charges and transfers: you charge the buyer on your platform and create the transfer to the seller later. Destination charges pay the seller automatically, so they cannot hold funds. Holding money adds liability and may bring licensing duties, so take legal advice first.

What happens to the seller's payout when a buyer gets a refund?

For a destination charge, set reverse_transfer on the refund and Stripe takes the seller's share back. Decide who absorbs your platform fee with refund_application_fee, and record the rule per transaction.

Which Stripe webhooks does a marketplace need to handle?

At minimum: account updates (seller onboarding status), payment success and failure, disputes, and payout success and failure. Register one endpoint for platform events and one for Connect events. Verify every signature and make handlers safe to run more than once.

Next Steps

If you're planning a marketplace payment flow, we can help in two ways:

How much should your build actually cost?

Get a personalized investment estimate based on your platform type, scope, and timeline.

Open the Investment Calculator
#stripe-connect#payment-processing#escrow#split-payments
Found this helpful? Share it
Share:

About the Author

Chris Mask

Chris Mask

Founder & Marketplace Strategist

Chris Mask is Directorism’s founder and marketplace strategist. He helps founders define operating models, scope platforms, and choose the right build path.