How to collect payments (Stripe & PayPal)
Accept one-time payments directly inside your forms using your own Stripe or PayPal account — with zero platform fees.
Spiceform lets you add a secure Payment block to any form so respondents can pay you directly. Payments are powered by a Bring Your Own Key (BYOK) model — you connect your own Stripe or PayPal account, and 100% of the money goes straight to you. Spiceform never touches or holds your funds, and we charge zero platform fees on transactions.
The Payment block is available on the Hot plan and above. If you're on the free Mild plan, you'll need to upgrade before you can add payments to your forms. Visit the Pricing page to compare plans.
How it works
- •You provide your own API keys in Settings. Spiceform stores them encrypted (AES-256) and only uses them to process payments on your behalf.
- •In the form builder, you add a Payment block, choose Stripe or PayPal, set a price, and publish.
- •Respondents see a secure checkout (Stripe Elements or PayPal Buttons) embedded directly in the form. They never leave the page.
- •The form only completes once payment succeeds. The amount is always verified server-side to prevent tampering.
Setting up Stripe
- 1Log in to your Stripe Dashboard at dashboard.stripe.com.
- 2Go to Developers → API Keys. Copy your Publishable key (starts with pk_live_ or pk_test_).
- 3For the Secret key, we strongly recommend creating a Restricted Key instead of using your full secret. Go to Developers → API Keys → Create restricted key. Enable these permissions: PaymentIntents (Write), PaymentMethods (Read). Name it something like "Spiceform".
- 4Copy the restricted key (starts with rk_live_ or rk_test_).
- 5In Spiceform, go to Settings → Billing tab. Find the "Payment Integration" card for Stripe.
- 6Paste both keys and click "Save & Validate". Spiceform will test the keys with a lightweight API call. If they pass, you'll see a green "Active" badge.
Using a Restricted Key limits Spiceform's access to only what it needs (creating charges and reading payment methods). This is a security best practice — even if the key were compromised, it could not access your full Stripe account.
Make sure both keys are from the same mode. Mixing a live publishable key with a test secret key (or vice versa) will fail validation.
Setting up PayPal
- 1Go to developer.paypal.com and log in with your PayPal Business account.
- 2Navigate to Apps & Credentials (under the Dashboard menu).
- 3Click "Create App". Give it a name like "Spiceform Payments" and select Merchant as the type.
- 4Once created, copy the Client ID and Secret Key from the app details page.
- 5In Spiceform, go to Settings → Billing tab. Find the "Payment Integration — PayPal" card.
- 6Paste both credentials and click "Save & Validate". Spiceform auto-detects whether the keys are Live or Sandbox and shows the appropriate badge.
You can start with Sandbox credentials to test the full checkout flow with fake money, then switch to Live credentials when you're ready to accept real payments.
Adding a Payment block in the builder
- 1Open your form in the builder.
- 2In the left sidebar, find the "Payment" block under the Form Elements section and drag it onto the canvas (or click to add).
- 3With the Payment block selected, the Properties sidebar on the right will show Payment Settings.
- 4Choose a Provider — Stripe or PayPal. A warning banner will appear if the selected provider's keys haven't been configured yet.
- 5Select the Currency (USD, EUR, GBP, and 13 more supported).
- 6Choose the Price Mode: Fixed Amount — enter the price in cents (e.g., 2500 = $25.00). The converted amount is shown below the input. Variable Amount — select a Calculator variable. The payment amount is dynamically computed from your form logic at runtime.
- 7Optionally, customize the Button Label (e.g., "Pay Now"), Product Name, and Product Description. These appear on the checkout screen and Stripe receipts.
Fixed vs. variable pricing
- •Fixed Amount — Use this for products or services with a set price. Enter the amount in the smallest currency unit (cents for USD/EUR, yen for JPY). Example: 5000 = $50.00.
- •Variable Amount — Use this when the total depends on the respondent's answers. First, create a variable in the Logic tab (e.g., "price") and set up calculator rules that compute the total based on form answers. Then select that variable in the Payment block's settings. The amount is locked on the server at checkout time, so respondents cannot manipulate it.
The minimum payment amount is 50 cents (or equivalent). Amounts below this will be rejected at checkout.
What respondents see
- •Stripe — A full Stripe Elements checkout with support for credit/debit cards, Apple Pay, Google Pay, and other local payment methods. The checkout appears inline within the form.
- •PayPal — Official PayPal Buttons rendered directly in the form. Respondents log in to their PayPal account to complete the payment.
- •Both providers show the exact amount, currency, and a security badge. If the payment fails, a clear error message is shown and respondents can retry.
After payment
- •The form only submits once payment is confirmed. If payment fails or is cancelled, the form stays on the payment step.
- •A successful payment is recorded in the Submissions table with full payment metadata (transaction ID, amount, currency, provider).
- •You can view payment status in real time from the Results tab. Failed payments are flagged so you can follow up.
- •You can view payment details in the Results tab alongside the rest of the submission data.
Security and trust
- •Your API keys are encrypted at rest using AES-256-GCM with per-user authentication, so even if the database were breached, keys cannot be decrypted without the server's encryption secret.
- •Payment amounts are always computed and verified on the server. The client-side form cannot override the price.
- •Spiceform never stores credit card numbers or PayPal credentials. All sensitive payment data is handled entirely by Stripe or PayPal.
- •Each payment is verified server-side before the form submission is finalized, preventing spoofed submissions.
Frequently asked questions
- •Does Spiceform take a cut? — No. Spiceform charges zero platform fees. Standard Stripe/PayPal processing fees still apply (set by Stripe/PayPal, not us).
- •Can I use test/sandbox keys? — Yes. Use Stripe test keys (pk_test_ / sk_test_) or PayPal Sandbox credentials to test the full flow with fake data before going live.
- •Can I use both Stripe and PayPal? — Yes. You can configure both providers in Settings and choose per Payment block which one to use.
- •What happens if a respondent closes the browser mid-payment? — The form auto-saves progress. If they return, they'll resume from the payment step. Any pending PaymentIntent or PayPal Order will be reused (idempotent).
- •Which currencies are supported? — USD, EUR, GBP, CAD, AUD, JPY, CHF, NZD, SEK, NOK, DKK, SGD, HKD, BRL, MXN, and INR.
Was this article helpful?