Build Your First App with Gemini
A hands-on guide for teachers and beginners. No coding experience needed — just a Google account and an idea.
You are the project manager. The AI is your developer.
How It Works
Here's the whole process in four steps. You don't need to understand code — you just describe what you want and the AI builds it.
- Describe your idea in plain English — "I need a tip calculator that splits the bill"
- AI writes the instructions — you'll get a working app in about 60 seconds
- Test and improve — try it out, tell the AI what to fix or change
- Share it — put it online with a link anyone can open
That's it. Now pick which AI tool to use:
Choose Your Path
Not sure which to pick? Start with Gemini Canvas — it's the easiest path and you'll see your app instantly. You can always try AI Studio later.
Use a personal Google account for both tools. School/Workspace for Education accounts have restrictions — notably, Workspace users cannot share Canvas creations. Personal accounts avoid all of these issues and are free.
Gemini + Canvas
gemini.google.com/canvasBuild and preview apps right in the chat. No file saving needed — Gemini renders your app live. The easiest starting point.
- Live preview — see your app instantly
- No file management needed
- Chat to iterate, or click elements to edit
- Free tier available (uses Flash model)
- Workspace/school accounts can't share links
- Lower daily usage limits than AI Studio
Google AI Studio
aistudio.google.comPaste a super prompt, describe your app, copy the code, save as an HTML file. More generous free tier and now has a "Build mode" with live preview too.
- Very generous free usage (hundreds of uses per day)
- Works with personal Google accounts
- Build mode has live preview + code editor
- See and understand the full code
- Slightly more setup than Canvas
- School accounts have limited access
Which model? Both paths use Gemini Flash by default, which is free and great for building apps. Stick with it — no need to upgrade or change anything.
The Super Prompt
This prompt tells Gemini how to behave. It produces a single HTML file — that's just a text file your browser knows how to display as a web page. Think of it as a recipe your browser follows.
You do NOT need to understand the text below. It's a set of instructions for the AI, not for you. Just click "Copy" and paste the whole thing. It works in both Gemini Canvas and AI Studio.
Click the "Copy" button in the top-right corner of the box below — it copies everything for you. Then paste it into Gemini before describing your app.
VIBE CODING ASSISTANT - Single File App Generator
You are an expert at creating simple, functional single-file web apps for coding novices. Your goal is to turn rough ideas into working prototypes that can be opened directly in a web browser.
CONSTRAINTS:
- Generate ONE complete HTML file containing CSS and JavaScript
- No external dependencies (libraries, APIs, or CDNs)
- Apps must work when opened locally on desktop
- Include clear, educational comments explaining key concepts
- Keep all responses under 200 words (except code generation)
CODE REQUIREMENTS:
- Use semantic HTML structure
- Include responsive CSS styling
- Add JavaScript for interactivity
- Comment major code sections and explain key functions
- Use modern but widely-supported syntax
SUGGESTED APP TYPES:
- Productivity tools (timers, calculators, note-takers)
- Simple games (memory, word games, puzzles)
- Utilities (unit converters, password generators)
- Trackers (habits, expenses, tasks)
- Educational tools (flashcards, quizzes)
WORKFLOW:
1. If user gives vague idea, ask 1-2 clarifying questions
2. Generate complete, commented code
3. Offer brief explanation of how data flows through the app
4. Suggest 2-3 simple modifications they could try
USER INSTRUCTION: Simply describe what kind of app you want to build, even if your idea is rough or incomplete. I'll help you create something functional!
What app would you like to build today?
Step-by-Step Guide
Click the tab for your chosen path, then follow the numbered steps.
1 Open Gemini Canvas
- Go to gemini.google.com/canvas (or open gemini.google.com and select "Canvas" from the input bar)
- Sign in with your personal Google account
- You'll see a chat interface with a Canvas workspace panel
Already logged into your school account? Open a private/incognito window (Ctrl+Shift+N in Chrome) and sign in with your personal Gmail there.
2 Paste the super prompt + describe your app
Paste the super prompt you copied (from above), then press Enter twice and type your app idea below it — all in one message. Example of what the full message looks like:
[the super prompt you already copied]
Build me a conference contact tracker. Simple text inputs for name, note, and follow-up action. Add a timestamp automatically. Let me copy everything to clipboard at the end.
Hit Send and wait 30–90 seconds. Gemini will think, then generate code.
If Gemini asks you a question instead of generating code, that's normal — it's trying to understand what you want. Just answer it and the code will come next.
3 See your app in Canvas
When Gemini generates HTML code, the Canvas panel on the right automatically shows a live preview of your app.
- Preview — see your working app, click buttons, enter text
- Code view — see and edit the HTML/CSS/JS code directly
- Click any element — describe what you want to change in plain English (annotation mode)
Try your app right there — click every button, fill in every field. Note what works and what doesn't.
4 Iterate in the chat
To make changes, just type what you want in the chat. Be specific — one change at a time:
Make the background dark gray and the text white. Keep buttons green.
The "add" button doesn't do anything when I click it. Fix just this.
Add a "clear all" button that removes everything from the list.
Canvas will update the preview automatically after each change.
5 Download your code
When you're happy with your app:
- Click the Code tab in the Canvas panel
- Select all the code (Ctrl+A / Cmd+A)
- Copy it (Ctrl+C / Cmd+C)
- Save as
index.htmlusing the instructions in the deploy section below
1 Open AI Studio
- Go to aistudio.google.com
- Sign in with your personal Google account (remember: not school/work). Already logged into a school account? Use an incognito window (Ctrl+Shift+N).
- Click "Create new prompt" in the top-left (if you see a popup about settings or model selection, dismiss it — defaults are fine)
AI Studio also has a "Build mode" at aistudio.google.com/build with live preview, similar to Canvas. Either approach works — the prompt-based workflow below is the most beginner-friendly.
2 Paste the super prompt
- Copy the entire super prompt from above
- Click into the message box at the bottom of AI Studio
- Paste it (Ctrl+V / Cmd+V)
Important: Click the save icon (floppy disk) in the top bar after pasting. AI Studio doesn't always auto-save.
3 Describe your app and generate
After the super prompt sends, type your app description in the next message:
Conference app to track people I meet. Simple text inputs for name, note, and follow-up action. Add a timestamp automatically. At the end, let me copy everything to clipboard.
Click Send and wait 30–90 seconds. You'll see Gemini "thinking" first — that's normal.
If Gemini asks a question instead of generating code, just answer it — the code will come next. When it's done, you'll see a big block of code.
4 Save the code as an HTML file
Copy the generated code — from <!DOCTYPE html> to </html>.
Mac instructions
- Open TextEdit (Cmd+Space, type "TextEdit")
- Go to Format → Make Plain Text (critical!)
- Paste your code (Cmd+V)
- File → Save, name it
index.html - Change "use .txt" to "Don't append"
- Save to Desktop
Windows instructions
- Open Notepad (search in Start menu)
- Paste your code (Ctrl+V)
- File → Save As
- Change "Save as type" to "All Files (*.*)"
- Name it
index.html - Save to Desktop
VS Code (either platform — easiest)
- Open VS Code (free at code.visualstudio.com)
- New file: Ctrl+N / Cmd+N
- Paste your code
- Save: Ctrl+S / Cmd+S, name it
index.html
5 Open and test your app
- Find
index.htmlon your Desktop - Double-click it — it opens in your browser
- Try every feature: click every button, fill every field
- Note what works and what doesn't
6 Iterate — make it better
Go back to AI Studio and ask for specific changes. One change at a time. Paste your full code.
Here's my current code: [paste code]
The "add" button doesn't work. Fix just this issue, don't change anything else.
After each new version: copy the new code → paste into your file (replace all) → save → refresh browser.
App Ideas
Stuck? Pick one from the table and make it yours. Good first apps do one thing well with 3 features or fewer.
| Category | App Ideas |
|---|---|
| Calculate | Tip splitter, unit converter, BMI calculator, loan payment estimator |
| Track | Habit streak, water intake, mood log, reading list, expense log |
| Organize | To-do list, packing checklist, meeting notes, contact tracker |
| Time | Pomodoro timer, countdown to event, stopwatch with laps |
| Classroom | Random name picker, quiz flashcards, exit ticket form, seating chart randomizer |
| Fun | Decision spinner, compliment generator, quote of the day, trivia game |
Pro tip: Describe your app with "I need a way to ___ so that ___." Example: "I need a way to track the people I meet at conferences so that I remember who to follow up with."
Prompting & Iteration Tips
The first version is never perfect — that's expected. The loop:
Write prompt → Generate → Test → Find problem → Improve prompt → Repeat
Golden Rules
- One change at a time. Don't ask for 5 things at once.
- Always paste your full code when asking for changes (AI Studio). Canvas remembers context.
- Be specific. "Fix the button" → "The Add Entry button doesn't respond when clicked. Fix just this."
- Describe what you see vs. what you expect. "When I click Submit, nothing happens. I expected it to add a new row to the list."
Useful Prompt Templates
Fix a bug
The [feature] isn't working. When I [do X], [Y happens] instead of [Z]. Fix just this issue, don't change anything else.
Add a feature
Here's my current code: [paste]. Add [specific feature]. Keep everything else the same.
Change the look
Change the color scheme to dark mode with a navy background and white text. Don't change any functionality.
Understand the code
Explain what the JavaScript section does in simple terms. I'm a complete beginner.
Start over
Start over. New version with these changes: [list what you want different].
Peek Under the Hood (Optional)
Curious how your app works? These prompts help you explore — totally optional. Pick whichever sounds useful:
- Just got it working? → Try Prompt 1 for a plain-English overview
- Want to tinker? → Try Prompt 2 for safe things to change in your code
- Need to fix or add something? → Jump to Prompt 3
Where's my code? Canvas users: click the Code tab in the Canvas panel and copy everything. AI Studio users: open your saved index.html file in a text editor and copy everything.
Prompt 1: "What Did I Build?" — The Big Picture
Use right after your app works. No code knowledge needed — gives you a visual overview of what your app does.
Copy this prompt, then paste your code after itI just built a web app with AI and I want to understand what it does at a HIGH LEVEL. Don't show me code — show me what happens from a user's perspective using simple diagrams.
Here's what I need:
1. THE APP IN ONE SENTENCE
What does this app do? (Plain English, one sentence.)
2. WHAT CAN THE USER DO?
List every action a user can take and what happens when they do it. Use a simple table:
USER DOES THIS | APP RESPONDS WITH
------------------------|---------------------------
[action] | [what happens]
3. THE MAIN FLOW (Step by Step)
Walk through the most common use case like a story:
STEP 1: User opens the app. They see: ___
STEP 2: User does ___. The app: ___
STEP 3: The app saves/processes ___
STEP 4: User sees ___
4. WHERE DOES DATA GO?
Show a simple diagram of how information flows:
User types something
↓
App receives it
↓
App stores it in ___
↓
App shows it on screen as ___
5. WHAT ARE THE "RULES"?
List 3-5 rules the app follows.
Example: "Names can't be empty" or "Data disappears when you refresh"
6. WHAT HAPPENS IN UNUSUAL SITUATIONS?
Show a table:
WHAT IF... | WHAT HAPPENS
-------------------------------|---------------------------
User submits empty form? | ___
User refreshes the page? | ___
User clicks Submit 100 times? | ___
Keep the language simple — explain this to someone who has never coded before. Use diagrams made of text characters, not just paragraphs.
Here's my code:
[PASTE YOUR index.html CODE HERE]
Prompt 2: "Walk Me Through the Code" — Guided Tour + Safe Experiments
Gives you a beginner-friendly code walkthrough plus 5 safe things to change in your code to learn by doing.
Copy this prompt, then paste your code after itI built this web app with AI and I want to understand how the code works. I'm a complete beginner — I don't know HTML, CSS, or JavaScript yet. Explain everything using simple language and visual diagrams.
Here's what I need:
PART A: THE LAYOUT (What's on screen)
Show me every visible element in my app like a map:
+-----------------------------------+
| [header area] |
+-----------------------------------+
| [input area] |
| [buttons] |
+-----------------------------------+
| [results/display area] |
+-----------------------------------+
PART B: THE STYLES (How things look)
Show me ONE example of how the CSS controls appearance:
.button {
background-color: #4CAF50; ← SAFE TO CHANGE: try "red" or "#FF5733"
padding: 10px 20px; ← SAFE TO CHANGE: bigger number = more space
border-radius: 5px; ← SAFE TO CHANGE: bigger = rounder corners
}
PART C: THE ACTIONS (What happens when you click things)
For each button or interactive element, show a flowchart:
User clicks button
↓
App reads the text box
↓
Is it empty?
YES → Show error
NO → Save data → Update display
PART D: 5 SAFE EXPERIMENTS TO TRY
Give me 5 things I can change in the code that are safe and will teach me something:
1. CHANGE A COLOR
2. CHANGE A SIZE
3. CHANGE A MESSAGE
4. ADD A DEBUG MESSAGE (console.log)
5. CHANGE A NUMBER
PART E: THE CHEAT SHEET
Show a translation table for common patterns in MY code:
WHAT IT DOES IN PLAIN ENGLISH | THE CODE THAT DOES IT
----------------------------------|---------------------------
"Find the button on the page" | document.querySelector('#btn')
"When button is clicked, do ___" | btn.addEventListener('click', ...)
Keep everything beginner-friendly. Quote the actual code from MY app.
Here's my code:
[PASTE YOUR index.html CODE HERE]
Scratch users: Add this line before pasting your code: "Also: I know Scratch programming. When explaining JavaScript concepts, compare them to Scratch blocks."
Prompt 3: "Help Me Fix or Change This" — The Tutor
Use when something is broken or you want to add a feature. This makes Gemini teach you, not just fix silently.
Copy this prompt, paste your code, then describe your problemI'm a complete beginner who built this web app with AI. I need help with something specific. Here are your rules:
YOUR ROLE:
- You are a patient tutor, not just a code fixer
- When I describe a problem, help me UNDERSTAND what's wrong — don't just fix it silently
- When I want to add something, walk me through the steps — don't just give me new code
- Celebrate what's already working before addressing what needs fixing
- Keep explanations under 200 words, then ask if I want more detail
HOW TO HELP ME DEBUG:
1. First, tell me what the problem probably is in plain English
2. Then show me exactly where to look (quote the code, don't use line numbers)
3. Tell me to add a console.log() to confirm the problem
4. Then show me the fix and explain WHY it fixes the problem
HOW TO HELP ME ADD FEATURES:
1. First, point out a similar pattern already in my code
2. Then break the new feature into 3 simple steps
3. Walk me through each step one at a time
4. After each step, tell me to save and test before continuing
WHAT NOT TO DO:
- Don't rewrite my entire app
- Don't add features I didn't ask for
- Don't use technical jargon without explaining it
Here's my code:
[PASTE YOUR index.html CODE HERE]
My question / what I want to change:
[DESCRIBE YOUR PROBLEM OR WHAT YOU WANT TO ADD]
Share Your App Online
Your app works — now put it on the internet so anyone can open it with a link.
Option A: Google Sites — Easiest (5 min, no new accounts)
- Go to sites.google.com
- Click "Blank site" (the + button)
- Name your site (top left)
- Click Insert → Embed in the right sidebar
- Click the "Embed code" tab
- Paste your entire
index.htmlcode - Click Next → Insert
- Click Publish (top right) → choose a URL slug → Publish
Your URL: https://sites.google.com/view/YOUR-SITE-NAME
Heads up: If your app saves data between visits (like a to-do list that remembers your items), that feature might not work inside Google Sites. If it seems broken after embedding, try GitHub Pages instead — it's more reliable.
Option B: GitHub Pages — More robust (10–15 min, needs GitHub account)
- Create a GitHub account at github.com/signup (use a personal email, pick a username you'll keep — it's part of your URL)
- Create a new project folder: Click + → New repository → name it lowercase, no spaces (e.g.
my-app) → Public → check "Add a README" → Create - Upload your file: Click Add file → Upload files → drag in
index.html→ click Save - Enable Pages: Settings → Pages → Source: "Deploy from a branch" → Branch: main → folder: / (root) → Save
- Wait 2 minutes, then refresh the Pages settings — look for the green banner with your URL
Your URL: https://YOUR-USERNAME.github.io/YOUR-REPO-NAME/
To update: Click the file on GitHub → pencil icon → replace code → Commit → wait 1–2 min → hard refresh (Ctrl+Shift+R)
Option C: Just email the file
Email index.html as an attachment. Recipient downloads it, double-clicks, and it opens in their browser. No accounts, no hosting.
Troubleshooting
File opened as text, not a web page
- Mac TextEdit: You forgot Format → Make Plain Text. Save again.
- Windows: You saved as
.txt. Rename the file and change.txtto.html. - Either: Right-click the file → Open With → Chrome (or Firefox)
App doesn't do anything when I click buttons
- Make sure you copied ALL the code — scroll to the bottom of Gemini's response and verify you got
</html> - Open browser console: press F12 → Console tab → look for red errors
- Copy the error text and paste it back to Gemini: "I'm getting this error: [paste]. Fix it."
Gemini stopped generating partway through
- Look for a "Continue" button and click it
- Or type: "Continue from where you left off — the code got cut off."
Google Sites shows a blank app
- Make sure you pasted the FULL code including
<!DOCTYPE html>at the start - Try a hard refresh: Ctrl+Shift+R / Cmd+Shift+R
- Some apps won't work inside Sites — try GitHub Pages instead
GitHub Pages shows 404
- Make sure the file is named exactly
index.html(lowercase, no spaces) - Wait 3 minutes — Pages takes time on the first deploy
- Check Settings → Pages — is it showing the green banner yet?
I have no idea what to build
Check the App Ideas table above for a full list of starter projects by category. Pick one that solves a problem you actually have — you'll be more motivated to finish it.
I want to start completely over
- Start a new chat (don't reuse the same one)
- Paste the super prompt again
- Describe the same app differently, or try a new idea
I'm completely stuck and nothing is working
Start fresh with the simplest possible test:
- Open a brand new Gemini chat
- Paste the super prompt
- Type:
Make me a button that says "Hello!" when I click it. - If that works, you know the tool is working — now try your real idea again with a simpler description
If even that doesn't work, ask your facilitator for help or try switching between Canvas and AI Studio.
Your Personal AI Workshop Coach
Want a guide that walks you through everything step-by-step, answers your questions, and cheers you on? Copy the prompt below and paste it into a brand-new Gemini chat (separate from the one where you're building your app). It turns Gemini into an interactive coach.
Works everywhere: Paste this into Gemini, ChatGPT, Claude, or any AI chat. Great for self-paced learning, teacher prep, or running a workshop where participants learn at their own pace. Yes, this includes the super prompt you already saw — that's intentional so the coach prompt is self-contained.Copy this entire block into a new AI chat
INTERACTIVE WORKSHOP COACH — Build Your First App with AI
You are a friendly, patient workshop coach helping a complete beginner build their first web app using AI. You have deep knowledge of the workshop material below. Your job is NOT to build the app yourself — it's to guide the participant through the process step by step.
YOUR STYLE:
- Warm, encouraging, zero jargon
- Ask one question at a time — don't overwhelm
- Celebrate small wins ("Nice! You've got a working app!")
- If they're stuck, offer 2-3 concrete options to pick from
- Keep responses short (under 150 words) unless they ask for detail
THE WORKSHOP FLOW:
You'll guide them through these phases. Don't skip ahead — go at their pace.
PHASE 1: PICK AN IDEA (2 min)
- Ask what problem they'd like to solve, or what would be useful in their day
- Help them fill in: "I need a way to ___ so that ___"
- Narrow to 3 core features max
- If stuck, offer these categories: Calculate | Track | Organize | Time | Classroom | Fun
- Example ideas: tip calculator, habit tracker, pomodoro timer, random name picker, contact tracker
PHASE 2: GENERATE THE APP
- Tell them to open gemini.google.com/canvas OR aistudio.google.com (their choice)
- If they're unsure which: Canvas = easiest (live preview in chat), AI Studio = more usage/control
- Give them this super prompt to paste first:
---
VIBE CODING ASSISTANT - Single File App Generator
You are an expert at creating simple, functional single-file web apps for coding novices. Your goal is to turn rough ideas into working prototypes that can be opened directly in a web browser.
CONSTRAINTS:
- Generate ONE complete HTML file containing CSS and JavaScript
- No external dependencies (libraries, APIs, or CDNs)
- Apps must work when opened locally on desktop
- Include clear, educational comments explaining key concepts
- Keep all responses under 200 words (except code generation)
CODE REQUIREMENTS:
- Use semantic HTML structure
- Include responsive CSS styling
- Add JavaScript for interactivity
- Comment major code sections and explain key functions
- Use modern but widely-supported syntax
WORKFLOW:
1. If user gives vague idea, ask 1-2 clarifying questions
2. Generate complete, commented code
3. Offer brief explanation of how data flows through the app
4. Suggest 2-3 simple modifications they could try
USER INSTRUCTION: Simply describe what kind of app you want to build, even if your idea is rough or incomplete. I'll help you create something functional!
What app would you like to build today?
---
- Then tell them to describe their app idea after the prompt
- Remind them: "You're the project manager. The AI is your developer."
PHASE 3: TEST AND TWEAK
- Canvas users: try the app right in the preview panel
- AI Studio users: walk them through saving as index.html and opening in browser
- Ask: "What works? What's missing? What's broken?"
- Teach iteration rules:
* One change at a time
* Be specific ("The Add button doesn't respond" not "fix it")
* Describe what you see vs. what you expected
* For AI Studio: always paste your full code when asking for changes
PHASE 4: UNDERSTAND (optional but valuable)
- If they want to learn what they built, offer these options:
A) "Want a big-picture overview of what your app does?" (no code)
B) "Want a guided tour of the code with safe things to try changing?" (beginner-friendly)
C) "Want help fixing or adding something specific?" (tutor mode)
- Guide them to paste their code + the appropriate follow-up prompt
PHASE 5: DEPLOY
- Ask if they want to share it with a URL
- Two options:
A) Google Sites (5 min, no accounts): sites.google.com > Blank site > Insert > Embed > paste code > Publish
B) GitHub Pages (10 min): github.com/signup > new repo > upload index.html > Settings > Pages > main branch
- Walk through whichever they pick, one step at a time
IMPORTANT NOTES:
- Use a personal Google account (not school/work) — school accounts have sharing restrictions
- Gemini Flash (the default free model) is great for this — no need to upgrade
- If they get an error, don't panic — copy the error text and paste it back to Gemini
- If code gets cut off, say "Continue from where you left off"
START THE CONVERSATION:
Introduce yourself briefly (2-3 sentences), then ask what they'd like to build today. If they don't have an idea, offer the category list. Keep it light and fun — this is about building something cool, not about being perfect.
Glossary
Real terms you'll hear developers use. You've already been doing all of this — now you know the words for it.
Remember: you describe what you want, the AI builds it. Have fun!