12 Fun JavaScript Projects for Teens (Beginner to Intermediate)
Updated
Twelve JavaScript project ideas for teens, from a dice roller to a small platform game, with what each project teaches and how long it takes.
The fastest way for a teen to get better at JavaScript is to build things. Tutorials teach the words; projects teach how to use them. Here are twelve projects, ordered from easiest to hardest. Each one lists the skills it practises, so your teen always knows why it is worth doing.
New to JavaScript? Do the free JavaScript tutorial for teens first. It covers everything you need for projects 1 to 6.
Beginner projects (1–2 hours each)
1. Dice roller
A button that shows a random number from 1 to 6, maybe as a big emoji die. Skills: Math.random(), Math.floor(), click events, textContent.
2. Clicker game
Every click adds a point; at 50 points you unlock a "double click" upgrade. Skills: variables, events, if, updating the page.
3. Magic 8-ball
Type a question, press the button, get a random answer from a list. Skills: arrays, random index, reading an input field.
4. Tip and split calculator
Enter a bill, a tip percentage and the number of friends; see what everyone pays. Skills: Number(), math, rounding with toFixed(2).
Getting comfortable (an afternoon each)
5. To-do list
Add tasks, tick them off, delete them. Bonus: save them with localStorage so they are still there tomorrow. Skills: createElement, appendChild, classList.toggle, arrays.
6. Quiz game
Five multiple-choice questions, a score and a result screen. Skills: arrays of objects, loops, functions, showing and hiding elements.
7. Reaction timer
The screen turns green at a random moment; click as fast as you can and see your time in milliseconds. Skills: setTimeout, Date.now(), game states.
8. Password strength checker
As you type, show whether the password is weak, OK or strong, and why. Skills: input events, string methods, conditions. (Great combined with our web safety course.)
Intermediate projects (a weekend each)
9. Snake
The classic. Arrow keys move the snake, food makes it longer, hitting the wall ends the game. Skills: canvas, keyboard events, game loop with setInterval, arrays as coordinates.
10. Weather card
Show today's weather for a city using a free weather API. Skills: fetch, JSON, async/await, handling errors.
11. Drawing app
Draw on a canvas with the mouse, pick colours and brush size, save the picture. Skills: mouse events, canvas drawing, toDataURL.
12. Mini platformer
A square that runs and jumps over gaps, with gravity. Skills: game loop, velocity and gravity, collision detection. This is where math class suddenly becomes useful.
Tips for finishing projects
- Start ugly. Make it work first, then make it pretty.
- One feature at a time. Get the button working before adding sounds and animations.
- Use the console.
console.logeverything you are unsure about. - Show someone. Sharing a link with a friend is the best motivation there is.
Want guided projects?
In the JavaScript & the Web course on HexoQuest, teens build step by step with checks and hints in every level, and at the end they create a browser game and download it as an HTML file to keep.
Try it now
Start with the free JavaScript tutorial for teens: 9 interactive lessons, no sign-up.