Make a Flappy Bird Game in Scratch (Step-by-Step for Kids)
Want to make a Flappy Bird game in Scratch? Awesome choice. In this KidsKod tutorial you will build a bird that flaps upward, falls with gravity, and dodges pipes. Follow the steps slowly — you can do this!
What you need
- A free Scratch account at scratch.mit.edu
- About 30–45 minutes
- Curiosity and a snack (optional but recommended)
Step 1: Create the bird sprite
- Click Create in Scratch.
- Choose a bird sprite (or draw one).
- Rename it to
Bird. - Place the bird near the left side of the stage.
Step 2: Add flapping controls
Use these blocks for the Bird:
when green flag clicked
go to x: -150 y: 0
set gravity to 0
forever
change y by gravity
change gravity by -0.5
if <key space pressed?> then
set gravity to 8
end
if <touching edge?> then
broadcast lose
end
end
Tip: Make a variable called gravity (for this sprite only).
Step 3: Make scrolling pipes
- Create a pipe sprite (two rectangles stacked with a gap).
- When the green flag is clicked, place the pipe on the right.
- Forever: move left, and when it leaves the screen, jump back to the right with a new random gap height.
when green flag clicked
forever
set x to 240
set y to pick random -80 to 80
repeat until <x position < -240>
change x by -6
end
end
Step 4: Keep score
- Make a variable named score (for all sprites).
- When a pipe passes the bird, change score by 1.
- Show the score on the stage.
Step 5: Win and lose messages
When the bird hits a pipe or the edge, broadcast lose, stop other scripts, and show “Try again!” You can also add a restart button sprite.
Make it cooler
- Add a whoosh sound when flapping
- Change costumes so wings flap
- Speed up pipes every 10 points
What you learned
You used variables, forever loops, sensing (keys and touching), and broadcasts — the same ideas real game developers use. Next, level up with a Scratch platformer on KidsKod!