Table of Contents
Scratch + AI Extensions: How Kids Add Machine Learning to First Programs
Scratch's AI extensions let kids build image classifiers, voice games, and text classifiers using real ML concepts — no prior coding needed. Here's what they actually learn.
A second-grader in Seattle built a program that tells her apart from her cat. She showed her class. Her teacher, who has a graduate degree in education, could not explain how it worked.
That’s Scratch + AI extensions — and the gap between what kids can build with these tools and what adults assume kids can understand about AI is genuinely wide right now.
Scratch is MIT’s free visual programming environment, used by over 100 million people worldwide. The AI extensions — most prominently the ML4Kids (Machine Learning for Kids) extension and Scratch’s native Text-to-Speech and Video Sensing blocks — let kids connect their visual programs to real machine learning models without writing a line of code. The result is programs that classify images, respond to voice commands, detect movement, and make text-based decisions.
These aren’t toy demonstrations. The underlying ML concepts kids encounter — training data, labels, model accuracy, and the tension between training performance and real-world performance — are the same concepts professional ML engineers wrestle with. The complexity is abstracted; the concepts are real.
What Scratch AI Extensions Actually Are
Scratch extensions are add-on blocks that connect programs to additional capabilities. The built-in extensions include Text-to-Speech (the program speaks out loud), Translate (real-time translation using Google’s API), and Video Sensing (detect movement through the camera).
The ML4Kids extension, created by Dale Lane at IBM, goes further: it connects Scratch to a machine learning training environment where kids can build and train their own classifiers, then use those classifiers inside their Scratch programs.
There are also third-party tools that integrate tightly with Scratch:
- Teachable Machine (Google) — train an image, sound, or pose classifier in the browser, then use the model in a Scratch project via the Teachable Machine extension
- ML4Kids — a full platform supporting image, text, numbers, and sound classification with a Scratch connector
- ScratchJr AI blocks — simplified AI blocks for ages 5–7
The workflow, once set up, looks like this:
- Kid creates a training dataset in the external tool (e.g., takes 30 photos of “apple” and 30 photos of “banana”)
- Trains the model (clicks a button; waits 30 seconds)
- Tests the model (holds up objects, watches what it predicts)
- Returns to Scratch, uses a block like “when camera sees [apple]: play apple sound”
- Builds a game or interactive project around the model’s predictions
What Real ML Concepts Kids Learn
This is the part that makes these tools genuinely educational, not just entertaining.
Training data. Kids immediately discover that the model only knows what they’ve shown it. If they train a “happy face” vs “sad face” classifier using only their own face, it won’t recognize emotions in other people’s faces reliably. This is a concrete, felt encounter with a fundamental ML concept: the model is only as good as the data it was trained on.
Labels and classification. The process of deciding what categories to train (what counts as “happy”? what counts as “sad”?) forces kids to think about how categories are defined. This is surprisingly philosophically interesting and leads to real questions: “What if someone is in between? What label does that get?”
Model accuracy. After training, the platform shows accuracy metrics. Kids who don’t understand statistics still understand “my model guesses right 70% of the time.” When they use the model in a project, they experience the gap between training accuracy (often high) and real-world performance (often lower). That gap has a name in ML: overfitting.
Iteration. A model that doesn’t perform well in the project prompts the kid to go back, add more training data, fix the labels, or reframe the problem. This is the exact feedback loop that ML engineers use professionally.
Bias. Kids who train on limited data sources run into this directly. Train a face detector on only one skin tone and it won’t work on others. This becomes a conversation.
Age and Experience Guide for Scratch AI Projects
Not all AI extensions are equally accessible at every age. Here’s what works at different stages:
Ages 7–8 (absolute beginners):
- Video Sensing blocks (wave your hand to make a sprite jump)
- Text-to-Speech (the program reads text out loud)
- Simple Teachable Machine pose projects (stand like a superhero to trigger an action)
- No training required for these — they use pre-built models
Ages 9–10 (some Scratch experience):
- Image classifier with Teachable Machine (classify objects, faces, drawings)
- Sound classifier (distinguish clapping from snapping)
- Simple ML4Kids text projects (“kind words” vs “unkind words” classifier)
Ages 11–13 (confident Scratch users):
- Multi-class image classifiers built into full games
- Text classifiers for chatbots or story-branching programs
- Combining multiple AI blocks (voice input + text classifier + TTS response)
Ages 12–14 (ready to move beyond Scratch):
- Exporting models to run in other environments
- Starting to ask “what’s happening inside the model?” — a natural bridge to Python and TensorFlow
What the Research Says About Scratch’s Learning Outcomes
Scratch has been studied more rigorously than most educational technologies, partly because it was built at MIT’s Media Lab and the researchers there have been tracking outcomes since its 2007 launch.
A 2023 meta-analysis in Computers & Education (Su & Yang) reviewed 89 studies on Scratch in K-12 settings and found strong positive effects on computational thinking, particularly for students ages 8–12. The study found that the effect was strongest when students built self-chosen projects rather than following prescribed tutorials — consistent with the project-based learning literature.
The MIT Media Lab’s own longitudinal research (Resnick et al., multiple papers 2008–2022) has documented that Scratch learners develop what researchers call “computational fluency” — not just the ability to write code, but the habit of thinking about problems in computational terms. This is distinct from programming skill and transfers across domains.
A 2021 study specifically on AI literacy interventions for middle schoolers (Long & Magerko, Georgia Tech) found that hands-on experience with machine learning tools produced significantly better understanding of how AI makes decisions than either watching AI demos or reading about AI. The “training a model yourself” experience was particularly effective for building accurate mental models of ML systems.
Research from the University of California, Berkeley’s AI4K12 initiative has documented that even brief encounters with training data and model performance — as little as two hours — produce durable improvements in how kids think about AI systems: more accurate, less anthropomorphic, and more appropriately skeptical.
Scratch AI vs. Google Teachable Machine — What’s Different
Parents and teachers often ask whether to use Scratch with ML4Kids or Google’s Teachable Machine directly. Both are free and browser-based. Here’s how they compare:
| Feature | Scratch + ML4Kids | Google Teachable Machine |
|---|---|---|
| Ages | 7+ | 9+ |
| Code required | None (visual blocks) | None (export/embed) |
| Model types | Image, text, sound, numbers | Image, sound, body pose |
| Integration with projects | Direct in Scratch | Requires export step |
| Training interface | Simple, child-focused | More professional-feeling |
| Accuracy feedback | Basic | Detailed, with preview |
| Best for | Younger kids, Scratch projects | Older kids, standalone demos |
| Commercial models available | No (trains from scratch) | No (trains from scratch) |
| Privacy | Data stays local option | Data processed by Google |
The best starting point for most families is Scratch + Teachable Machine together: use Teachable Machine for the training (it’s more visual and satisfying) and then connect the model to a Scratch project using the Teachable Machine Scratch extension. This gives you the best of both.
Five AI Projects Kids Can Build With Scratch This Week
Rock-Paper-Scissors without touching the keyboard
Train an image classifier with three categories: hand showing rock, paper, scissors. Connect to a Scratch game that “plays” against the kid using the webcam. The game detects the hand sign and picks its own move. Kids immediately understand training data — they need enough photos of each sign, in different positions, for the model to be reliable.
A “mood light” that responds to facial expressions
Train a classifier: smiling face, frowning face, surprised face. Connect to Scratch sprites that change color or play sound based on detected mood. This one leads to immediate experiments: does it work in different lighting? On other family members? The answers introduce concepts of training set diversity.
A voice-controlled sprite game
Using the Speech Recognition extension, a sprite responds to spoken words (“jump,” “run,” “stop”). The kid designs the game; the AI handles the voice detection. This doesn’t require training — it uses a pre-built model — but kids often adjust commands to words the model recognizes better, which is itself an exercise in understanding model capabilities.
A “kind words / unkind words” text classifier chatbot
Train a text classifier with examples of kind messages and unkind messages. Build a Scratch chatbot that responds differently based on which category the input falls into. This project leads to important conversations about how the training data defines what “kind” means to the model — and the limitations of that.
A creature identifier for nature walks
Take photos outdoors of different plants, insects, or birds. Train a classifier with three or four local species the kid can find in the neighborhood or schoolyard. Build a project where the kid holds the camera up to something outside and the program tries to identify it. This project almost always fails more than it succeeds — which is the point, and the conversation it generates about model limitations is valuable.
What to Watch for Over 3 Months
In the first few sessions, the main learning is happening even if the kid doesn’t seem to be “studying” anything. Watch for moments when they start to explain why a model is getting things wrong — that’s the concept of training data limitations clicking.
By weeks four through six, a kid who’s built two or three AI Scratch projects will start making predictions about new models before they test them. “I think it won’t work because I only took photos in my room.” That’s genuine ML intuition.
By month three, the most revealing question to ask is: “When you trained your model, what decisions did you make?” If they can describe their training data choices and connect those choices to model behavior, they understand something most adults who use AI products daily don’t understand.
A flag worth watching: some kids become attached to the “magic” of AI and prefer not to understand why it works. This isn’t harmful, but it’s a missed learning opportunity. Concrete questions (“Why do you think it got that wrong?”) tend to break through the magic framing.
FAQ
What age is Scratch + AI appropriate for?
The basic video sensing and text-to-speech blocks work for kids as young as 6–7 with adult support. The training-your-own-model projects are best for ages 9+ independently. Younger kids can participate with a parent or teacher setting up the training environment.
Does my kid need to already know Scratch before trying AI extensions?
For ML4Kids and Teachable Machine projects, at least some Scratch experience helps — ideally a month or two of basic projects. For the simpler extensions (Video Sensing, Text-to-Speech), a beginner with no prior Scratch experience can follow along.
Is there a cost?
Scratch is free. ML4Kids is free. Teachable Machine is free. The only thing needed is a computer with a camera (for image/pose projects) or microphone (for sound projects) and a browser. No accounts are required for Scratch or Teachable Machine. ML4Kids requires an account for saving work.
How does Scratch AI compare to kids just playing with ChatGPT?
They’re different learning experiences. Scratch AI teaches how machine learning models are built — training data, labels, accuracy. Playing with ChatGPT (or being a user of AI) teaches prompting and output evaluation but doesn’t expose the underlying mechanics. Both are valuable; Scratch AI provides a much clearer window into how AI systems actually work.
Can my kid transition from Scratch AI to real machine learning later?
Yes, and it’s a natural path. Scratch AI introduces the vocabulary and intuitions. Python with scikit-learn or TensorFlow applies them in a real programming environment. Many kids who start with Scratch AI find the Python ML courses easier because the concepts aren’t new — just the implementation tools are.
About the author
Ricky Flores is the founder of HiWave Makers and an electrical engineer with 15+ years of experience building consumer technology at Apple, Samsung, and Texas Instruments. He writes about how kids learn to build, think, and create in a tech-saturated world. Read more at hiwavemakers.com.
Sources
-
Su, J., & Yang, W. (2023). “Scratch as a visual programming tool for K-12 computational thinking: A systematic review.” Computers & Education, 196, 104722. https://doi.org/10.1016/j.compedu.2023.104722
-
Resnick, M., & Rusk, N. (2020). “Coding at a crossroads.” Communications of the ACM, 63(11), 120–127. https://doi.org/10.1145/3375546
-
Long, D., & Magerko, B. (2020). “What is AI literacy? Competencies and design considerations.” Proceedings of the 2020 CHI Conference on Human Factors in Computing Systems. https://doi.org/10.1145/3313831.3376727
-
Maloney, J., Resnick, M., Rusk, N., Silverman, B., & Eastmond, E. (2010). “The Scratch programming language and environment.” ACM Transactions on Computing Education, 10(4), 16. https://doi.org/10.1145/1868358.1868363
-
AI4K12 Initiative. (2022). Five Big Ideas in AI: K-12 Guidelines. CSTA & AAAI. https://ai4k12.org/
-
Lane, D. (2023). Machine Learning for Kids. IBM. https://machinelearningforkids.co.uk/
-
Google. (2024). Teachable Machine. https://teachablemachine.withgoogle.com/
Related reading: why coding is the new literacy for kids in 2026, computational thinking vs. coding — what kids really need, and unplugged coding activities for kids without computers.