Skip to content

ttcd77/form-handler

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Form Handler for Google Sheets

An open-source toolkit that pipes your static website's contact form submissions into Google Sheets — with email notifications, spam protection, and rate limiting. MIT-licensed, free forever.

Views MIT License

📖 Read the tutorial: How to Build a Contact Form Backend for $0/Month Using Google Sheets — full step-by-step walkthrough with code snippets, competitor pricing comparison, and architecture deep-dive.

📢 Also on DEV Community — developer discussion and reactions.

The Problem

Freelancers and agencies building static sites hit the same wall: the client wants a contact form, but nobody wants to set up a backend for 5 lines of HTML.

Existing solutions charge monthly:

  • web3forms Pro: $10/month for Google Sheets integration → $120/year
  • Formspree: $20/month for file uploads + Sheets
  • Formcarry: $15/month for 5,000 submissions

For a marketing site that gets 20 submissions a month, that's $120-240/year for a feature the client barely uses.

The Solution

Form Handler replaces all of that with a free Google Apps Script. Paste it in, deploy it once, and it runs forever on Google's infrastructure (free — 20,000 emails/day, unlimited sheet rows).

Features

  • Google Sheets integration — submissions land directly in a spreadsheet
  • Email notification — instant alerts for new submissions
  • Spam protection — honeypot field detection + keyword blocklist
  • Rate limiting — per-IP submission cap, configurable per hour
  • Auto-responder — templated "thanks" email back to every submitter
  • JSON + form-urlencoded — supports both content types
  • Origin whitelisting — restrict submissions to your domains

Installation

  1. Go to script.google.com and create a new project
  2. Copy form-handler.gs into the editor
  3. Deploy as a Web app (Execute as: Me, Access: Anyone)
  4. Update the configuration object at the top of the script with your email and sheet name
  5. Add the form from example-form.html to your static site
  6. Replace YOUR_SCRIPT_URL with your deployment URL

Submissions now flow into your Google Sheet. Done.

License

MIT — you own the code. Use it for unlimited clients, bundle it with your agency projects, modify it however you want.

More from selfloom

  • URL Environment Switcher — One-click Chrome extension to jump between localhost, staging, and production while preserving path, query, and hash. Free, MIT licensed.

Built by

selfloom — we build tools for developers who hate subscriptions.

About

Free Google Apps Script that pipes HTML forms into Google Sheets with email notifications and spam protection. No monthly subscription.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors