Introduction
Setting up an e-commerce store that accepts cryptocurrency does not require Stripe or any other centralized payment processor. Cloudflare Pages combined with NOWPayments provides a fully self-custodied, globally deployable stack that can go live in under 48 hours. The infrastructure is GitHub-driven, worker-based, and free of third-party custody. This guide evaluates the stack components purely on technical and financial criteria: fees, settlement times, custody models, and geographic reach.
Required Components
The core stack consists of four parts: a static storefront, a crypto payment processor, a serverless backend for order processing, and a globally distributed CDN.
The storefront is built with a static site generator hosted on Cloudflare Pages. This eliminates server costs, provides automatic CI/CD from GitHub, and leverages Cloudflares global edge network for sub-second latency. NOWPayments integrates via a JavaScript widget embedded in the storefront. Payments are routed to the merchants self-custodied wallet without intermediaries. No transaction fees are charged by Cloudflare Pages for static hosting under 500 GB bandwidth per month. NOWPayments charges 0.5 % per transaction with no fixed fees.
A Cloudflare Worker acts as the lightweight backend. It receives webhooks from NOWPayments upon payment confirmation, updates the order status in a KV namespace, and sends emails via a transactional service. Workers cost $0.015 per million requests, and KV storage is $0.50 per GB per month. There are no bandwidth egress fees within Cloudflares network, which reduces unpredictability in cloud costs.
Geographic reach is handled by Cloudflares 300+ edge locations and NOWPayments support for 100+ cryptocurrencies across 180+ fiat currencies. The stack is not restricted by card network rules, regional licensing, or IBAN requirements.
Step-by-Step Deployment
Start by creating a new GitHub repository with a static site generator such as Astro, Next.js Static Export, or Hugo. Connect the repository to Cloudflare Pages via the Pages dashboard. Enable build commands and environment variables directly in the UI; no external secrets manager is required. Cloudflare Pages will automatically provision a .pages.dev subdomain.
Add NOWPayments to the storefront by including their JavaScript library. Configure the widget to specify which cryptocurrencies are accepted and provide the merchants wallet addresses or a NOWPayments invoice address. The library is under 200 KB, which keeps page load times low.
Next, create a Cloudflare Worker script that listens for the NOWPayments webhook event payment.completed. The worker retrieves the order ID from the webhook body, validates the signature using a pre-shared key, then updates the corresponding order in KV. Use Wrangler to deploy the worker directly from the command line. Worker scripts average 2 ms execution time globally and use minimal CPU cycles, so the cost remains below $1 for thousands of orders.
Finally, configure KV for persistence. Create a namespace called ORDERS and add an index for order_id. The namespace will store order data in Cloudflares edge network, which is replicated across multiple data centers. This approach avoids vendor lock-in and provides millisecond read times worldwide.
Cost and Performance Benchmarks
Static hosting on Cloudflare Pages costs $0.00005 per GB of storage and $0.10 per GB of bandwidth after the free tier. Under typical e-commerce traffic of 5,000 visits per month and 200 KB page size, bandwidth costs total approximately $1.00. Workers incur $0.000015 per request; at 1,000 requests per month, this is $0.015. NOWPayments fees at 0.5 % on a $100 order equate to $0.50. Total monthly infrastructure cost is under $2 without any volume discounts applied.
Settlement occurs on-chain and varies by blockchain. Bitcoin and Ethereum settlements average 10–60 minutes. Lightning Network settlements are near-instant and cost less than $0.01 in fees. These times are directly visible to the customer via NOWPayments payment status page. There is no risk of chargebacks, and funds are under full merchant control from the moment the transaction is confirmed.
Geographic latency tests across Cloudflares edge network show median response times of 25 ms in North America, 40 ms in Europe, and 70 ms in Asia-Pacific. The static site and worker respond from the nearest location, eliminating the need for a separate CDN contract.
Limitations and Mitigations
The stacks primary limitation is self-custody risk. If the merchant loses seed phrases or wallet passwords, funds are irrecoverable. Mitigation involves using multi-signature wallets or hardware wallets with passphrase backups stored in geographically separate safes.
Another risk is price volatility. NOWPayments offers the option to auto-convert received crypto to stablecoins or fiat via integrated exchanges. This feature adds a 1 % fee but removes volatility exposure. Merchants should decide whether to absorb volatility or pass it to customers via price surcharges.
Regulatory exposure exists in jurisdictions that classify crypto payments as money transmission. Cloudflare Pages and Workers do not require licensing, but NOWPayments does. The company holds licenses in the EU through its Lithuanian entity and in the US through state-by-state registrations. Merchants outside these regions should review local regulations independently.
Conclusion
Cloudflare Pages combined with NOWPayments and a Cloudflare Worker provides a self-custodied, globally scalable