Skip to content
Code Craft — web development and digital marketing
HTML + PHP Shop Add-onv1.0.0

Stripe Payments Add-on for HTML + PHP Shops

Take card, Apple Pay and Google Pay payments in the Code Craft PHP shops through Stripe Checkout

No reviews yetUpdated October 2026 Live preview
Live demo

Everything included

  • Stripe Checkout Sessions (hosted payment page)
  • Session re-read from Stripe on return
  • Webhook signature with a 5-minute tolerance
  • Idempotency key on session creation
  • Amount and currency checked against the order
  • Settings and licence key in Admin → Add-ons
How it works

From order to a live website

Try the live demo
  1. 1

    Buy the add-on

    One-time price. Your download link and licence key arrive by email and in My Account.

  2. 2

    Drop it in

    Upload the folder into addons/ on your hosting.

  3. 3

    Switch it on

    Turn it on in Admin → Add-ons, add the licence key and your settings.

What it does

Adds Stripe as a payment method to the Code Craft HTML + PHP shop templates. At checkout the customer is sent to Stripe's hosted Checkout page for the exact server-calculated total. When they come back, the add-on reads the Checkout Session from Stripe before marking the order paid, and Stripe's webhook is accepted only with a valid, recent signature. The shop engine compares the paid amount and currency with the order. You need your own Stripe account. The add-on follows Stripe's Checkout Sessions and webhook documentation and was tested against mocked Stripe responses, not with real payments.

  • Stripe Checkout Sessions (hosted payment page)
  • Session re-read from Stripe on return
  • Webhook signature with a 5-minute tolerance
  • Idempotency key on session creation

Works with

This add-on is for the 12 Code Craft HTML + PHP shop templates (Kora, Annapurna, Bunkar, Giftsy, Harit, Mithas, Nazar, Petal, PhoneZone, Pukka, Pustak, WoodCraft). It is sold separately and has its own licence key. Upload its folder into the website's addons/ folder and switch it on in Admin → Add-ons; no code changes.

  • Site core 1.1 or later
  • Drop-in folder, no code changes
  • Its own settings screen and licence key

Who it is for

It is for owners of one of the 12 Code Craft HTML + PHP shop templates (Kora, Annapurna, Bunkar, Giftsy, Harit, Mithas, Nazar, Petal, PhoneZone, Pukka, Pustak and WoodCraft) who want card payments, plus Apple Pay and Google Pay where Stripe shows them on its page. You need your own Stripe account and, for the webhook, your site on HTTPS. Card details are typed on Stripe's hosted Checkout page, never on your site, and nothing is installed with Composer.

  • One of the 12 shop templates, site core 1.1+
  • Your own Stripe account
  • HTTPS for the webhook

Setting it up

Upload the stripe folder into addons/, switch on Stripe payments in Admin → Add-ons and open its Settings. Paste the add-on licence key and your secret key from Stripe → Developers → API keys (sk_test_ while you test; a restricted rk_ key with Checkout Sessions write access also works). Change the name at checkout if you like (default: Pay by card (Stripe)). In Stripe → Developers → Webhooks, add the address shown on the settings screen, …/cc/endpoint.php?addon=stripe&action=webhook, with the events checkout.session.completed and checkout.session.async_payment_succeeded, and paste its whsec_ secret. Keep the method ticked in Admin → Shop → Payments.

  • Secret key or restricted key
  • Webhook URL printed on the settings screen
  • Two events to select in Stripe

What the customer sees

When the customer places the order, they are sent straight to Stripe Checkout for the order total, with their email filled in and a line reading Order and the number with your business name. After paying they come back to their order page; the add-on re-reads the Checkout Session from Stripe and the order shows as paid once Stripe reports it paid and the amount matches. If they cancel, they return to their order page and can press Pay now to try again; within the same hour the same order reuses Stripe's session through an idempotency key instead of opening a second one. If they close the tab after paying, the signed webhook marks the order paid.

  • Straight to Stripe's hosted page
  • Session re-read on return
  • Retry from the order page

Honest limits

It was tested only on local copies of the Kora and Pustak templates with real PHP 8.3 and every Stripe call answered by a mock server (47 checks per shop together with the other gateways): session created with the server total, currency and idempotency key, a return before payment, a return with another session refused, a tampered or five-minute-old webhook refused and a lower amount not paid. It has not processed real money. Refunds, payouts and disputes are handled in your Stripe Dashboard, and Stripe decides which currencies your account supports.

  • Mocked responses only
  • Refunds are made in Stripe
  • Stripe fees apply

After the payment: what you see in the admin

In Admin → Shop → Orders the order moves from pending to paid and the payment is recorded with Stripe's payment intent id. The customer gets the status email, and you get a payment email if owner notifications are on in Shop settings. A payment for the wrong amount or currency is not accepted: it is recorded as a mismatch, and a note on the order shows what was received and what was expected. A payment that arrives after you have already changed the order's status is recorded with a note asking you to check it. Problems talking to Stripe are written to the website's private log in data/.

  • Payment recorded on the order
  • Mismatch notes in the order history
  • Errors in the private log

More ready-made websites

Built by the same team, with the same setup service and support.

Browse every ready-made website, or compare our custom website packages if you need a site designed from scratch. Want more guests to find you on Google Maps? See our local SEO service, or talk to our web design team.