Ecosystem Simulator
A meadow, sixty rabbits, six foxes, and the oldest cycle in ecology running live. Tune the balance, watch the waves, and see how long your little world can last.
The meadow fell silent
What is the Ecosystem Simulator?
This is a living predator–prey model. The meadow is a grid of 1,440 grass patches; sixty rabbits graze it and six foxes hunt them, and every single animal is an individual agent with its own position and energy. Rabbits wander, eat, and breed when well fed. Foxes chase the nearest rabbit they can see, feast or starve, and breed only after several successful hunts. Nothing else is scripted — the famous boom-and-bust population waves you will see in the graph emerge entirely from those simple rules.
That emergence is the lesson. Ecology textbooks draw tidy sine-like curves of lynx and hare populations chasing each other; here you can watch the same pattern build itself out of individual animals bumping into each other, and then — because the meadow is small — watch it eventually fail. Keeping all three species alive is the game. On the balanced preset, half of all runs last beyond five minutes; the hungry-foxes preset usually collapses within thirty seconds, and understanding why is most of an ecology lecture.
How to Use It
The Rules Every Animal Follows
Grass is the energy source. A grazed patch takes a set number of ticks to regrow (the first slider — 20 by default), so the meadow can only feed so many rabbits per second, no matter how many are born.
Rabbits move one patch per tick, eat grown grass for energy, pay one energy per tick to stay alive, and split into two when their energy crosses the fertility threshold (the second slider). Too many rabbits strip the meadow faster than it regrows, and the herd starves — a carrying-capacity crash with no fox involved.
Foxes can see rabbits two patches away and chase the nearest one. A catch feeds them (the third slider sets how much); missing meals drains them, and like rabbits they breed by splitting when well fed. Foxes live on the edge: a fox needs several catches to breed, so when rabbits get scarce, the fox population thins within seconds — and if it thins to zero, the run is over.
Things to Try
Four experiments, each demonstrating a real ecological effect:
Watch the predator lag
Pause, restart, and watch the graph's first minute. The rabbit line rises first; the fox line copies it a few seconds later, then overshoots and drags the rabbits down. That offset between the two waves is the signature of every predator–prey system, from plankton to lynx.
Crash the meadow without a single fox
Push rabbit fertility to its easiest setting and grass regrowth to its slowest. The herd booms, strips the meadow bare, and starves — often before the foxes matter at all. Overpopulation crashes are a food-supply story, and this slider pair tells it in under a minute.
Prove that efficient predators destroy themselves
Load Hungry foxes. Feeding foxes more per catch sounds good for foxes — but they multiply, eat the meadow empty, and starve as a group, usually within thirty seconds. Predator efficiency is self-limiting; the fox population's worst enemy is its own success.
Hunt for the long run
The balanced preset survives past five minutes half the time — but not always, because tiny populations can die of pure bad luck. That is small-population extinction risk, the same reason isolated nature reserves lose species. Your best time is partly skill, partly variance, exactly like real conservation.
Honest Limits
This is a toy world, honestly sized. The meadow wraps around at the edges, animals have no age or sex (they reproduce by splitting), foxes never fight each other, and weather, disease and seasons do not exist. Those omissions are what keep the model readable: with only three sliders, every collapse can be traced to a cause. The dynamics that survive the simplification — the predator lag, the overgrazing crash, the small-population extinctions — are the same ones field ecologists measure, which is exactly why this class of model (an agent-based predator–prey lattice) is a standard teaching tool.
FAQ
Is the Ecosystem Simulator free?
Yes — the simulator is completely free and runs instantly in your browser. There is no download, no sign-up, and nothing to install.
Is every animal really simulated?
Yes. Each rabbit and each fox is an individual agent with its own position and energy: rabbits wander, graze and breed when well fed; foxes hunt the nearest rabbit they can see and starve if they fail. The population graph is just a count of those individuals over time — the boom-and-bust waves emerge from the rules, they are not scripted.
Why does my ecosystem always collapse eventually?
Because it is small. In a meadow this size the fox population runs on a handful of individuals, and a run of bad luck — a few hungry foxes missing a few rabbits — can wipe them out. Real conservation biology calls this small-population extinction risk, and it is why isolated nature reserves lose species even when the average balance looks fine. Bigger, better-connected habitats survive longer for exactly the reason your longest runs do.
What do the three sliders change?
Grass regrowth sets how many ticks a grazed patch needs to grow back — the meadow's food supply. Rabbit fertility sets how much energy a rabbit needs before it breeds. Fox appetite sets how much energy a fox gains per catch — hungrier foxes hunt the meadow empty. Small changes to any of them visibly reshape the population waves within a minute.
Is my best survival time saved?
Yes. Your longest run — the time until the first species died out — is stored in your browser's local storage on this device. No account is needed, and clearing your browser data resets it.