‹ YuzoolGuideOpen app

Website Maker guide

A Google Forms alternative that writes to your own sheet

If you like how Google Forms fills a spreadsheet but want your own form on your own page, Website Maker can do the same job. You paste a short script into a Google Sheet of yours once. After that, every reply to your form becomes a new row in that sheet, with nothing stored by Yuzool and no server in between.

Updated · 5 min read

How it works

A Google Sheet can run a small script of its own, and Google gives that script a web address. Your form posts each reply to that address, and the script adds it to the sheet as a new row. So:

  • The sheet is yours, in your own Google account. Share it, sort it and chart it as you like.
  • The form is yours too: your questions, your colours, on your own page, with no Google branding.
  • Visitors need no account. They fill in the form and press Send.
  • Nothing passes through Yuzool. The reply goes from the visitor’s browser to Google, and that’s all.

Set it up, step by step

You need a Google account and about five minutes. You don’t need to understand the script. In Website Maker, open your form block and tap Send replies to my Google Sheet: the same steps are there, with a button that copies the script.

  1. Open a Google Sheet. A new, empty one is best (type sheets.new in your browser). Replies go in its first tab.
  2. Open Apps Script. In the sheet’s menu along the top, choose Extensions, then Apps Script. A new tab opens with a few lines of code in it.
  3. Paste the script. In Website Maker, press Copy the script. In the Apps Script tab, click in the code, select all of it and paste over it. Press the Save icon.
  4. Deploy it. At the top right, press Deploy, then New deployment. Press the cog beside “Select type” and choose Web app. Set “Execute as” to Me and “Who has access” to Anyone. Press Deploy.
  5. Say yes to Google. Press Authorise access and choose your account. If Google says it hasn’t verified this app, that’s normal for a script of your own: press Advanced, then “Go to” your project’s name, then Allow.
  6. Copy the Web app URL. It starts https://script.google.com/macros/s/ and ends /exec. Paste it into Website Maker, then press Send a test row. Look at your sheet: a new row is there, with your questions along the top.
If the test row doesn’t arrive

In Apps Script, press Deploy, then Manage deployments, and check that “Who has access” says Anyone. Then copy the Web app URL again. An address that ends /dev is the test address and only works for you.

The script, in full

This is all of it. It adds a row to the sheet it lives in, and writes your questions along the top the first time. It can’t see your other files, and it never sends your answers anywhere. An answer that a sheet would treat as a formula is kept as plain words, so nobody can slip a formula into your sheet.

// Website Maker on Yuzool: form replies into this sheet.
// It does one thing: each reply becomes a new row in the first tab.
// It only adds rows: it never shows your sheet to anyone, and it sends nothing anywhere.

function doPost(e) {
  var sheet = SpreadsheetApp.getActiveSpreadsheet().getSheets()[0];
  var questions = e.parameters.q || [];
  var answers = e.parameters.a || [];
  if (sheet.getLastRow() === 0) {
    sheet.appendRow(['Date sent'].concat(questions.map(asText)));
  }
  sheet.appendRow([new Date()].concat(answers.map(asText)));
  return ContentService.createTextOutput('{"ok":true}')
    .setMimeType(ContentService.MimeType.JSON);
}

// Keeps an answer as plain words, so nobody can slip a formula into your sheet
// (and a phone number keeps its first 0).
function asText(value) {
  var text = String(value).slice(0, 20000);
  return /^[=+\-@]|^0\d/.test(text) ? "'" + text : text;
}

// Opening the web app address in a browser shows this line, so you know it works.
function doGet() {
  return ContentService.createTextOutput('This address takes form replies for your sheet. It is working.');
}

Where it works

Replies go to your sheet from two places:

  • Your short link, such as yuzool.com/site/your-name, which is part of Website Maker Pro.
  • Your downloaded site, hosted at your own address.

On the long free link, the form works as it always has: Send opens the visitor’s own email, WhatsApp or messages with the answers ready to go. Keep that filled in as well. If a reply ever can’t reach your sheet, the form says so and offers that way instead, so nothing is lost.

What a sheet form won’t ask

When a reply goes by email, the visitor sees it leave. A reply to a sheet is sent quietly, so these forms have rules that protect the people filling them in:

  • No passwords, PINs, card or bank details or security codes. Website Maker refuses a question that asks for one and tells you why. Such a form sends by email instead.
  • A fixed line under the form, which you can’t remove: “Your answers go to this site’s owner, in their Google Sheet.”
  • Report this site stays at the foot of every page on a Yuzool link.

What it can’t do

There are still no file uploads and no summary charts (make charts in the sheet itself). The top row is written once, from the first reply, so if you add or move questions later, start a new sheet or clear the old one so the columns line up. Anyone who has the web app address can add rows, though never read them. To switch it off, press Deploy, then Manage deployments, then Archive in Apps Script.

If you’d rather not use Google at all, the free way still works: replies by email or WhatsApp, pasted into Form replies to make a table. See a Google Forms alternative without an account.

Questions

Do the people filling in the form need a Google account?

No. They open your link and press Send. Only you need a Google account, for the sheet.

Is this free?

Forms are free in Website Maker, with replies by email, WhatsApp or text. Sending replies to a Google Sheet is part of Website Maker Pro ($2.99 once), because it works on your short link, which is Pro too. It also works in a site you download and host yourself.

Can Yuzool see my replies?

No. Each reply goes from the visitor’s browser straight to your sheet through Google. Nothing passes through Yuzool and nothing is stored by Yuzool.

What does the script do?

It adds one row to the sheet it lives in for each reply, and writes your questions along the top the first time. It is about a dozen lines, and you can read all of it before you paste it.

Why does Google say it hasn’t verified this app?

Google shows that for any script you make yourself. The script is yours and runs only in your sheet. Press Advanced, then “Go to” your project’s name, then Allow.

What if a reply can’t be sent?

The form says so and offers to send the answers by email, WhatsApp or text instead, so the reply isn’t lost.

Can my form ask for a password or card number?

No. A form that sends to a sheet can’t ask for passwords, PINs, card or bank details or security codes. Website Maker refuses those questions, and visitors always see the line “Your answers go to this site’s owner, in their Google Sheet.”