You need to take payments. You've narrowed it to Stripe, PayPal, or Square — the three biggest, most trusted payment APIs in the industry. Picking between them isn't about which is "best" in the abstract. It's about which one matches your customers, your volume, and your team's engineering capacity.
We've built on all three. Here's the honest comparison.
The verdict up front#
| You care most about... | Pick |
|---|---|
| Fastest integration, best developer experience | Stripe |
| Maximum global reach and consumer trust | PayPal |
| In-person payments and small-business tooling | Square |
| Subscription billing | Stripe |
| Marketplace / multi-party payouts | Stripe (Connect) |
| Lowest in-person card fees | Square |
If you're a pure-online business building in a supported country, default to Stripe unless you have a specific reason not to. The rest of this article explains when those reasons exist.
At-a-glance comparison#
Developer experience#
Stripe#
Stripe set the bar for payments APIs, and the bar is still Stripe. The things that stand out after years of building on it:
- Documentation that works as reference and tutorial. Every endpoint has working examples in curl, Node, Python, PHP, Ruby, Go, Java, and .NET.
- Idempotency keys on every mutation — retry safely without creating duplicates.
- Test mode is a full mirror of production. Webhooks, disputes, invoices, refunds — all testable without real money.
- Versioned APIs with a clean upgrade story. Your integration keeps working on the version you chose until you explicitly upgrade.
import Stripe from "stripe";
const stripe = new Stripe(process.env.STRIPE_SECRET_KEY!);
const paymentIntent = await stripe.paymentIntents.create({
amount: 2000, // $20.00 in cents
currency: "usd",
payment_method_types: ["card"],
metadata: { orderId: "ord_01H9" }
});
// Pass paymentIntent.client_secret to the browser.PayPal#
PayPal has improved dramatically in the last few years. The v2 Orders API is REST-based and clean. But there are still quirks:
- Multiple checkout experiences (Checkout, Standard, Express) with overlapping capabilities
- OAuth token management (your server fetches a bearer token and refreshes it)
- Region-specific behavior you'll hit in edge cases
const token = await getAccessToken(); // OAuth2 client_credentials grant
const res = await fetch("https://api-m.paypal.com/v2/checkout/orders", {
method: "POST",
headers: {
"Content-Type": "application/json",
Authorization: `Bearer ${token}`
},
body: JSON.stringify({
intent: "CAPTURE",
purchase_units: [{ amount: { currency_code: "USD", value: "20.00" } }]
})
});
const order = await res.json();
// Redirect the user to order.links.find(l => l.rel === "approve").hrefSquare#
Square's API surface is broad because it spans POS, inventory, and online. For pure online payments, it's clean and simple:
import { Client } from "square";
const client = new Client({
accessToken: process.env.SQUARE_ACCESS_TOKEN!,
environment: "production"
});
const response = await client.paymentsApi.createPayment({
sourceId: "cnon:card-nonce-from-web-sdk",
idempotencyKey: crypto.randomUUID(),
amountMoney: { amount: 2000n, currency: "USD" }
});Fees compared.#
Headline rates are similar. The differences show up in the details.
| Stripe | PayPal | Square | |
|---|---|---|---|
| Online (card) | 2.9% + $0.30 | 2.99% + $0.49 | 2.9% + $0.30 |
| Online (ACH) | 0.8% (capped $5) | 3.49% + $0.49 | 1% + $0.25 (min $1) |
| In-person (swiped) | 2.7% + $0.05 | 2.29% + $0.09 | 2.6% + $0.10 |
| International card | +1.5% | varies by region | +1.5% |
| Chargeback fee | $15 | $20 | $0 |
Ecosystem and extras#
Stripe has the deepest ecosystem:
- Billing — subscriptions, invoices, dunning, tax calculation
- Connect — marketplaces, multi-party payouts
- Terminal — in-person card readers
- Issuing — issue your own virtual or physical cards
- Radar — ML-powered fraud scoring
- Atlas — US incorporation for international founders
PayPal offers:
- Venmo checkout (US consumer reach)
- Pay Later (BNPL) bundled with checkout
- Payouts to 200+ countries
- Mass payments for gig economy apps
Square offers:
- Square Terminal / Register — hardware
- Orders, Inventory, Catalog APIs for retail
- Square Appointments for service businesses
- Cash App Pay integration
When to pick which#
Pick Stripe when...#
- You're building a SaaS, marketplace, or subscription business
- You want the fastest time to a shipped integration
- Your customers expect Apple Pay, Google Pay, Link, and card out of the box
- You care about webhook reliability and test-mode fidelity
Pick PayPal when...#
- You need to accept payments in countries Stripe doesn't support
- Your target customers strongly trust the PayPal brand (common in certain markets and demographics)
- You need consumer-facing BNPL (Pay Later) without building it yourself
- You're selling cross-border with mixed currencies
Pick Square when...#
- You're a physical retail or food business adding online sales
- You want unified hardware, POS, inventory, and online checkout
- Your in-person volume is larger than your online volume
- You're a small business that values out-of-the-box tooling over API depth
Can you use two at once?#
Yes — and many businesses do. A common pattern:
- Stripe for cards + Apple Pay as the primary checkout
- PayPal as a secondary button to capture users who prefer it
The lift to add PayPal as an alternate payment method is a few days of work, and the incremental conversion is usually worth it if your audience skews international or mature.
Related reading#
- Twilio SMS API tutorial — add payment confirmation and order alert SMS to your checkout flow.
- SendGrid vs Mailgun vs Postmark compared — send transactional receipts and invoices alongside your payment integration.
- Browse all Payments & Fintech APIs.
Start with Stripe's test mode
Spin up an account in minutes, hit the API with test keys, and see why developers default to it.