Free · no signup · nothing to install

Ant Colony

No ant knows where the food is or which way is shortest. Each one follows a few simple rules: wander, pick up food, leave a scent on the way home, follow a scent when you smell one. Out of that, a colony finds the shortest path to a picnic, and nobody planned it. Ant Colony lets students watch it happen in a backyard, see the trails with Smell view, ride along with one ant, and then change the rules every ant follows to find out which ones the colony cannot do without.

The colony is already working. Click any ant to ride along, turn on Smell view to see the trails, and open Rules to see what every ant is told. Space pauses. Nothing is saved to us.

Open it full screen

Using this with a class? Make a free class and add your students yourself: each gets a username and password, with no email or Google account needed. Or give them one join code. Using Google Classroom? Post the link there; with a free class, the link also puts each student in your class, so you see their work.A first lesson: Everyone opens The Double Bridge, where two paths of different lengths lead to the same food, and watches a day with Smell view on. Which path won, and how did the ants know? Then each student removes one rule card from the ants' rules and runs the day again. Whose colony still found the food, and which card was the one it could not live without?

Set up a free class Share to Google Classroom

What a student actually does

They open the lab on a backyard where a colony is already working. Ants leave the nest, wander, find a cookie or a sugar cube, and carry crumbs home. Clicking an ant rides along with it, and Smell view shows the scent the ants leave: food trails that grow stronger as more ants use them and fade when they stop. The clock runs from morning through the night, day after day, until winter comes. Then the season ends: the colony makes it through the winter only if its pantry holds one piece of food for every ant.

They paint the yard. Food goes down, an apple bit, bread crust, cheese, a cookie, a grape, a popsicle, and so do things in the way, rocks, a log, a hose, a puddle, a hedge, a paving stone. Moving a rock makes the colony find a new way round. Four more yards set up questions: The Double Bridge has two paths of different lengths to the same food, The Long Way Round makes the short way hard, Picnic spreads food everywhere, and The Spider puts a hunter in the yard.

Then the rules. Every ant runs the same short list, top to bottom, over and over: always walk; when I smell food, turn toward it; when I am carrying food, turn toward the nest and leave a food scent; when I smell a food trail, follow it. The rules are cards with dropdowns, written in plain words, and the same rules open as blocks in a Glassbox drawer or as code. The queen has rules of her own: whether to hatch a forager, a soldier, or nothing and save the food, by how full the pantry is, how big the colony is, whether an enemy was seen today, and whether winter is close.

Change a card and run the day again. Take away the card that tells a carrying ant to head home, and the colony gathers nothing. Make the scent fade too fast, and no trail can form. Take away wandering, and the colony still finds food, which surprises most students. Add soldiers, and an alarm scent, and the colony can face the spider. A shared colony runs on its page, catching up on the time since it was saved.

The foragers' rules open in a Glassbox drawer beside the yard, titled My ants' rules: every ant runs these rules top to bottom, over and over, all day, and a later rule can overrule an earlier one. The cards: when always, walk; when always, wander a little; when I am about to bump into something, steer around it; when I am getting tired, turn toward the nest; when I can smell food, turn toward the food; when food is right in front of me, pick up the food. Each condition and action is a dropdown, with buttons to add and or, move a card up or down, or delete it. Above, Rules, Easy Blocks and Blocks.

The foragers' rules, as cards. Each one is a dropdown in plain words, and the same list opens as blocks or as code. Take one away and run the day again to find out whether the colony needed it.

What they are learning while they play

Nothing here is presented as a lesson. This is what the activity is made of.

What the student doesWhat it is
Watches the colony pick the shorter of two bridges Emergent behavior. No ant compares the two paths. Ants on the short path get back sooner, so its scent builds faster, so more ants take it. The choice belongs to the colony, not to any ant.
Turns on Smell view and watches a trail grow and fade Communication by pheromones. Ants talk through scent left on the ground. A trail is a message that gets louder when it is used and fades when it is not, which is how the colony forgets a picnic that is gone.
Removes one rule card and runs the day again Rules, sequence and testing. Every ant runs the list top to bottom. Taking one card away is an experiment, and the gathered count says whether the colony needed it.
Moves a rock and watches the colony find a way round Adapting without a plan. Nothing tells the ants the rock moved. Their rules find the new way anyway, which is why simple rules can be stronger than a map.
Makes the scent fade faster until no trail forms Parameters and thresholds. Below a certain fade rate a trail cannot build up faster than it disappears. Finding that line is finding where the system changes behavior.
Reads the rules as blocks and then as code From rules to code. The cards are if-statements. Seeing the same rules in all three forms shows what a program is: a list of when-this-do-that, run over and over.

How to tell whether it landed

Ask, and let them show you. A student who has understood it can answer these without help.

Use it in your subject

Not a technology class? Then the app is how students show what they learned in your unit. More projects for every subject.

Biology

Run The Double Bridge with Smell view on and explain, step by step, how pheromone trails let a colony find the shorter path.

Computer science

Remove one rule at a time and record what the colony gathered each day. Explain which rules are load-bearing and why.

Math

Change how fast the scent fades and chart the food gathered against it. Find the rate where trails stop forming.

Science fair

Ask a question about ant behavior, test it in the yard with one thing changed, and compare the result with a real colony on the sidewalk.

Practical notes

For co-ops, microschools, and classrooms

Give everyone the same yard and the same question, which rule can the colony not live without, and compare answers. With a free account the colonies are saved and shared, and a shared colony keeps running on its page.

Common questions

Is Ant Colony free?

Yes. It runs in your browser and there is no paid tier. A free account adds saving and sharing, but nothing on this page is behind a paywall.

Does my child need an account to try it?

No. The demo on this page opens on a working colony. Make a free account to save a colony, share it, and use the other yards.

Is it real ant behavior?

The main idea is: ants find food and the shortest way to it by following scent trails that strengthen with use and fade with time, and the double bridge is a famous experiment with real ants. The numbers, how fast scent fades or how much an ant can carry, are chosen so the colony behaves the way real ones do, not measured from one species.

Do I need to know how to code?

No. The rules are cards in plain words with dropdowns. Students who want to can open the same rules as blocks or as code.

Is the spider scary?

It is a cartoon hunter in the yard, and the colony can learn to deal with it. Nothing is graphic.

What subject can I log this as?

Most families log it as biology or science, or computer science when the rules are the point. The table above lists specifically what is covered, so you can pick the label your records need and point at the evidence.

Still have a question? Ask us, and a person will write back.

Where to go next

Start with Ant Colony

Trying it costs nothing and takes about five minutes. An account is what makes the work last.

Ant Colony is one of the making apps on the platform. It is a place to make things, not a course, and it is not a substitute for a teacher: it is at its best when an adult asks the questions above and takes the answers seriously.
Page last reviewed October 2026.