form-builder

Form Builder

A web app that lets you paste questions with options & answer keys and instantly generate a Google Form. Just sign in with Google and go.

Live app: https://gformbuild.vercel.app/


What it does


How to use

1. Sign in

Visit the app and click Sign in with Google. Use any Google account that has been added as a test user (see Setup below). Your forms will be created in your own Google Drive.

2. Fill in form details

3. Paste your questions

Use this format in the text box:

1. What is the capital of France?
a) London
b) Paris ✓
c) Berlin
d) Rome

2. Which of these are prime numbers?
a) 2 ✓
b) 4
c) 7 ✓
d) 9

3. What is the chemical symbol for water?
Answer: H2O

4. Multiple choice using Answer line:
a) Option A
b) Option B
c) Option C
Answer: b

Marking correct answers — three ways:

Question types are auto-detected:

4. Generate

Click Generate Form. The app calls the Google Forms API and creates the form in your account. You get two links:


Format reference

Format Example
Question 1. Question text?
Option with correct mark b) Paris ✓ or b) Paris *
Answer line Answer: b or Answer: 1889
Option prefixes supported a) A. a. A) 1. 1)

Setup (developer — one time)

Requirements

Google Cloud Console

  1. Go to console.cloud.google.com
  2. Create a new project
  3. Enable Google Forms API and Google Drive API under APIs & Services → Library
  4. Go to OAuth consent screen → External → fill in app name and email
  5. Under Test users → add the Gmail addresses of everyone who will use the app (up to 100)
  6. Go to Credentials → Create OAuth 2.0 Client ID → Web application
  7. Add your Vercel URL under Authorized JavaScript origins (no trailing slash)
  8. Copy the Client ID

Add Client ID to code

In index.html, find this line and replace with your actual Client ID:

const CLIENT_ID = 'YOUR_CLIENT_ID_HERE';

Deploy to Vercel

  1. Push index.html to a GitHub repo
  2. Connect the repo to vercel.com
  3. Vercel deploys automatically on every push

Adding new users

Go to Google Cloud Console → OAuth consent screen → Test users → Add users. No redeployment needed. Users are not notified — share the link with them manually.


Notes


Tech stack

License

MIT — free to use, modify, and distribute.


Contributing

Found a bug or have a feature idea? Open an issue — contributions welcome.


Built with vanilla JS · Powered by Google Forms API · Hosted on Vercel