How I Built a Self-Hosted PayPal & Stripe Checkout (and Why I Avoided Middlemen)

Published: (December 28, 2025 at 12:43 PM EST)
3 min read
Source: Dev.to

Source: Dev.to

Accepting payments should be easy.

Yet every time I started a new side project or SaaS, I found myself stuck choosing between:

  • Copy‑pasting PayPal buttons from outdated docs
  • Wrestling with Stripe Checkout flows I didn’t fully control
  • Using hosted tools that added fees, lock‑in, or abstraction I didn’t need

I wanted something simpler:

👉 a small, self‑hosted layer that turns a snippet into a real PayPal or Stripe payment button

No middleman. No platform lock‑in. My keys, my server, my funds.

So I built one.

The problem with “just use Stripe / PayPal”

Don’t get me wrong — Stripe and PayPal are great payment processors.
The problem isn’t them. It’s everything around them.

Common issues I kept hitting:

  • Too much boilerplate for simple payments
  • Different flows for PayPal vs Stripe

Hosted tools that:

  • Take a cut
  • Store transaction data
  • Break when pricing changes

Little control over UI and behavior.

For many projects, I just wanted:

  • A button
  • A price
  • A callback
  • Done

What I wanted instead

My requirements were simple:

  • ✅ Self‑hosted
  • ✅ Works with my own PayPal & Stripe API keys
  • ✅ No transaction fees
  • ✅ Simple embed snippet
  • ✅ Optional cloud version for people who don’t want to host

That was the idea behind what eventually became FreshLimePay.

How it works (high level)

The core idea is intentionally boring (on purpose):

  1. You connect your PayPal or Stripe keys.
  2. You define a product or amount.
  3. The system generates a small snippet.
  4. That snippet renders a real checkout button.

Payment goes directly to your account — no proxying money, no holding funds, no “platform wallet”.

Example: from snippet to button

The goal was something like this:

PayPal

Integrate PayPal

Stripe

Integrate Stripe

And you instantly get a working payment button. That’s it.

Self‑Hosted vs Cloud (why I support both)

While building this, I realized something important: not everyone wants to self‑host. So FreshLimePay ended up with two modes:

🔒 Self‑Hosted

  • Install on your own server
  • Full control
  • One‑time or yearly license
  • Best for developers, agencies, SaaS founders

☁️ Cloud

  • No installation
  • Instant setup
  • Subscription model
  • Best for non‑technical users or quick launches

Same idea. Same philosophy. Different levels of control.

Why self‑hosting still matters (for some of us)

Self‑hosting isn’t about nostalgia. It’s about:

  • Ownership
  • Predictable costs
  • Fewer dependencies
  • Sleeping better when pricing pages change elsewhere 😅

If you’re a developer, you probably know the feeling.

If you don’t want to build this yourself

I packaged this into FreshLimePay so others wouldn’t have to rebuild the same thing again and again.

  • Website:
  • Cloud app:

If you do want to build your own — great. If you don’t, this might save you some time.

Final thoughts

This isn’t meant to replace Stripe or PayPal. It’s meant to make them simpler to use, especially for small products, MVPs, and indie projects.

If you’re interested, I’m happy to answer questions or share more implementation details in the comments.

Thanks for reading 👋

Back to Blog

Related posts

Read more »