EDGE Signal 449
Static site contact form implemented with Cloudflare Workers and reCAPTCHA v3 to block spam
A static site contact form uses Cloudflare Workers to process submissions and reCAPTCHA v3 to filter spam without a backend server.
Engineers maintaining static sites without backend infrastructure can now add contact forms that process submissions and block spam at the edge. This approach avoids vendor lock-in to platform-specific form services while keeping costs low.
Written by elseif from the cluster below · every claim links back to a sourceThe three things worth knowing
Cloudflare Workers handle form submissions for static sites lacking backend servers.
reCAPTCHA v3 provides spam filtering without requiring user interaction or visible challenges.
The solution replaces third-party form services with a self-hosted edge function and email delivery API.
THE READ
What the cluster adds up to.
A static site contact form now runs entirely on Cloudflare’s edge network. The form collects user input and sends it to a Cloudflare Worker, which processes the data and forwards it via an email delivery service. This eliminates the need for a traditional backend server or a platform-specific form service like Netlify Forms. The implementation targets engineers who host static sites on Cloudflare Pages and want to avoid vendor lock-in or additional costs from third-party form providers.
reCAPTCHA v3 replaces visible CAPTCHAs or user challenges with a score-based system that runs in the background. The service assigns a risk score to each submission, allowing the Worker to filter out likely spam before processing the message. This reduces friction for legitimate users while maintaining spam protection. However, reCAPTCHA v3 requires a Google account and API keys, which may introduce privacy considerations or dependency on Google’s infrastructure for some teams.
The solution integrates with Resend or MailChannels for email delivery, replacing the need for a self-hosted SMTP server. Cloudflare Workers handle the form submission logic, including validation and spam filtering, while the email service delivers the message to the site owner. This setup keeps costs low, as both Cloudflare Workers and Resend offer free tiers. However, the free tier limits may require upgrades as traffic or email volume increases, and the solution does not address long-term storage or management of submissions beyond email delivery.
Alternatives like Formspree, Formspark, or Botpoison offer similar functionality but tie the site to a third-party service. The Cloudflare Workers approach provides more control over the submission pipeline and avoids recurring costs for low-traffic sites. However, it requires more setup and maintenance than a managed service, including handling API keys, configuring Workers, and integrating with an email delivery provider. Engineers must also monitor spam filter performance and adjust thresholds as needed to balance false positives and spam leakage.
Written by elseif from the cluster below · checked for specifics the sources never containedTHE CLUSTER
↗