Schelling's segregation model, playableA Third Is Enough
Give everyone on this grid the mildest preference imaginable — "I don't mind being a minority; I just don't want to be outnumbered worse than two-to-one" — and a perfectly mixed city sorts itself into hard, single-colour blocks that nobody asked for. Not because anyone is a bigot. Because everyone is a little bit choosy, and choices compound. Thomas Schelling proved it in 1971. Here it is, running, with the gap between what people want and what they get measured live.
Two kinds of people share a grid — call them gold and teal — with some cells left empty. Each person looks at their up-to-eight neighbours and is content as long as at least a fraction τ of the neighbours they can see are their own kind. Anyone who isn't content picks up and moves to a random empty cell. That's the entire model. Nobody wants a segregated city; the sharpest preference on offer here is "please don't leave me almost alone." Watch what a whole grid of that mild wish produces.
The grid — set the wish, then press play
Press play. Each person only wants a third of their neighbours to match — but watch where the grid settles.
Press play at the default setting — τ = 1/3 — and the salt-and-pepper mix unmixes. Within a dozen-odd rounds the churn stops: the grid has broken into broad territories of one colour, veined with the empty cells people fled through. Now read the two numbers. The grid started with each person having about 50% same-kind neighbours — exactly what a random mix gives. It ends at about 76%.
Everyone asked for a third. Everyone got three-quarters.
That is the whole paradox in one line, and it is worth sitting with. No individual on the grid wants a segregated world. Each would be perfectly content in a neighbourhood that is two-thirds other. Yet the only arrangement in which they are all content is one where the average person is surrounded overwhelmingly by their own kind. The preference is mild and the outcome is extreme, and nothing bridges the two except the fact that one person's move makes a neighbour a little more outnumbered, who then moves, and nudges someone else. Segregation here is not anyone's goal. It is the fixed point the small wishes happen to have.
And here is the part that should unsettle you: everyone is happy
Look at the second number when the motion stops: zero people still want to move. The segregated grid is not a tragedy anyone is trapped in — it is an equilibrium everyone accepts. You cannot fix it by asking people to be content, because they already are. You cannot point to the culprit, because there isn't one. A social outcome that no member of the society wanted, and that no member is unhappy with, is the specific thing Schelling built this toy to make visible — and the reason it earned him a share of the 2005 Nobel Prize in economics.1
What you ask for, versus what you get
Slide the preference up and down and the endpoint moves with it — but never to where you pointed. This curve is the summary: for each value of τ, the height of the gold line is where the grid actually settles (averaged over many seeds; every point recomputed offline). The pale diagonal is the honest expectation — if the world gave you exactly the mix you asked for, it would sit on that line. It never does. The whole region between the two is the paradox.
The tipping curve
The gap between the two lines is segregation nobody chose. Run the grid above and a dot marks where your run landed.
Two features of that curve are real discoveries, not decoration. First, the gold line sits above the diagonal everywhere — even a whisper of preference (τ = 0.15) leaves the grid measurably more sorted than chance. There is no "safe" mild level that stays mixed. Second, follow the line to the right and it doesn't just keep rising — just past τ = 0.75 it falls off a cliff, crashing back down to the mixed baseline.
The cliff is not magic — it's counting
Past that point people are too picky, and the paradox inverts: there is no arrangement that contents everyone, so the grid never settles. It churns forever, and a grid in permanent churn stays roughly as mixed as it started. The exact location of the cliff is pure arithmetic. With eight neighbours, wanting "≥ 75% the same" means 6 of 8 — reachable inside a solid block. Wanting anything more than 75% rounds up to needing 7 of 8, which almost no cell on a real grid can satisfy at once. So the demand for near-total similarity defeats itself: ask for a little company and you get a wall; ask for near-total company and you get restless noise. The τ > 0.75 collapse is the model telling the truth about an impossible wish.
Don't take the numbers on trust — reproduce one
This grid runs a seeded pseudo-random generator, so a given seed produces the identical run here and in the offline verifier. Press the button: it loads seed 12345 at τ = 0.30, runs it to the end, and should land on the number the verifier prints.
Expected (from research/schelling/verify.mjs): start 0.5010 → end 0.7638, settled in 18 rounds, 0 unhappy.
What this does and doesn't say
It is tempting to walk away from this grid believing it has explained the segregated city outside your window. It hasn't, and pretending otherwise would betray the one thing the model is good for. Here is the honest reading, which is more interesting than the lazy one.
The model proves a sufficiency, not a cause. It shows that mild same-kind preference is enough, all by itself, to produce stark segregation — you don't need hatred, money, or law to get there. That is a genuine and counterintuitive result: it means observing a segregated city tells you less about people's inner attitudes than you'd think, because even tolerant people generate it. But "sufficient" is not "actual." Real-world residential segregation is over-determined — driven by income and housing cost, by explicit discrimination, by lending and zoning and school catchments, by history this toy contains none of. Schelling's grid removes all of that on purpose, to isolate one mechanism, and its lesson is precisely about that one mechanism, not the whole phenomenon.2
Two more caveats the honest version keeps in view. The grid is perfectly symmetric — the two groups are identical, equally numerous, with identical preferences and no difference in power or wealth. Real segregation is none of those things, and the symmetry is a limitation, not a neutrality. And the exact number — 76% at τ = 1/3 — depends on the rules stated here (eight neighbours, a bounded grid, moves to a random empty cell). Change the neighbourhood or the moving rule and the number shifts; what does not shift, across every variant studied, is the direction: mild preference, strong sorting.3 The moral is robust. The decimal is ours, and you can check it.
The check — every number here is recomputed, not quoted
- The grid you play IS the verifier. The simulation on this page (makeGrid / step / likeFraction) is copied byte-for-byte from research/schelling/sim.mjs, driven by the same seeded PRNG (mulberry32). A named seed produces a bit-identical run in your browser and on the command line.
- The headline, reproduced. 50×50 grid, 10% empty, τ = 1/3, averaged over seeds 1–40: mean start like-fraction 0.4994 → end 0.7568, and every run settles with 0 unhappy. Preference 0.333, outcome 0.757 — a gap of 0.42.
- The single run you can watch and check. Seed 12345, τ = 0.30: 0.5010 → 0.7638 in exactly 18 rounds, 0 unhappy. (The button above runs it live.)
- The monotone rise and the freeze are both verified. Segregation is non-decreasing across τ ∈ [0.20, 0.75] (0.576 → 0.999); at τ = 0.76 it never settles (40/40 seeds churn to the round cap) and stays at 0.51. The cliff is checked from the rule itself: 6-of-8 is content at 0.75 but not at 0.76.
- Robust to the arbitrary choices. The τ = 1/3 outcome stays in 0.75–0.76 across grid sizes 30–80 and vacancy 5–30% — it's the mechanism, not a tuned instance.
- Self-tests: an all-one-colour patch scores like-fraction exactly 1; a checkerboard scores below 0.5 (anti-clustered). Offline verifier: 24/24 checks pass.