Skip to content
Rennan Chagas

Data story · Brazil 2026

Where did the votes go?

The ballot is secret, so nobody can say how any one person voted twice. But with half a million ballot boxes and some careful statistics, we can reconstruct how the electorate moved between October 4 and October 25.

On October 4, 2026, 125 million Brazilians cast a ballot for president. Flávio Bolsonaro finished first with 56.1 million votes, Lula second with 53.9 million, and three other candidates — Augusto Cury, Renan Santos and Ronaldo Caiado — shared another 8.7 million. Three weeks later, in the runoff, Lula won with 64.3 million votes to Flávio’s 59.8 million.

Between the two rounds Lula added 10.4 million votes and Flávio added 3.7 million. The obvious question: where did those votes come from? Did the voters of the eliminated candidates decide it? Did people who stayed home in round one come back?

The problem: a secret ballot

Brazil’s electoral court (the TSE) publishes the result of every ballot box, about half a million of them, each serving roughly 300 voters. It’s a wonderful dataset. But it only says how many people in a box voted for each candidate. It never says whether someone who voted for Cury in round one chose Lula or Flávio in round two. Nobody knows that, not even the court. That is what a secret ballot means.

Opinion polls can ask people directly, but they reach a few thousand out of 158 million, rely on memory, and not everyone answers honestly or at all. So we took a complementary route: let the ballot boxes tell the story.

The idea: compare ballot boxes

Picture a few dozen towns. In each we know two things: what share of voters backed Candidate X in round one, and how well Lula did in round two. If Lula did better in the towns where X had more voters, X’s voters probably went to Lula. Draw a line through the dots; where it reaches the right-hand edge (a town made only of X-voters) tells you how X-voters behaved.

Why comparing ballot boxes works, and when it fails

Each dot is an imaginary town. The line is what a statistician would draw through the dots.

nonestrong
Illustration with made-up data. In this made-up world, 70% of Candidate X’s voters really went to Lula, and 22% of everyone else did.

The real analysis does this for nine groups of voters at once (Lula’s, Flávio’s, each eliminated candidate’s, blank, null, and people who stayed home) across about 499,000 ballot boxes. The family of methods is called ecological inference and is decades old; we adapt to this election the modified Brown–Payne model of Forcina, Gnaldi and Bracalente (2012), in the form described by Antonio Forcina and Jose M. Pavía (2026).

Now move the slider. It adds a “neighborhood effect”: X-voters behave differently where they are plentiful than where they are rare. The line then gives a wrong answer, even though the dots still look tidy. That is the method’s main weakness, and we’ll come back to it.

The big picture

Here is the result for the whole country. The left side shows what people did in round one, the right side what they did in round two, and the ribbons show how voters flowed in between.

Where each group of voters ended up

Left: what people did on October 4. Right: what the same ballot boxes did on October 25. Ribbon width = number of voters.

Hover over a bar to follow one group. Choose a place on the left; the other charts follow. Technical note: about 65 thousand voters whose registration moved between ballot boxes are left out of the picture (0.04%).
First thing to notice

Most voters did not move at all. We estimate that 97.3% of Lula’s first-round voters and 95.1% of Flávio’s voted for them again. Each side’s biggest leak was people staying home (2.4% of Lula’s, 3.5% of Flávio’s). Direct switching between the finalists was small: about 0.67 million Flávio voters moved to Lula, and only about 82 thousand the other way.

What decided the runoff?

If the finalists’ own bases mostly held, the contest was about everyone else. Think of three crowds up for grabs.

What decided the runoff?

Where each finalist’s second-round votes came from, by type of first-round voter.

Estimates for the selected place. “Net advantage” subtracts Flávio’s votes from Lula’s within each group; the four bars add up to the final margin.

Switch the chart to Net advantage to see the arithmetic. Lula’s final margin of about 4.4 million is made of roughly 2.5 million from first-round non-voters and 2.2 million from blank and null voters. The eliminated candidates’ voters contribute about nothing, and the finalists’ own first-round bases net out slightly against Lula (0.3 million), because Flávio started with the larger base.

A caveat on the “even split”

This is where our estimate and the opinion polls disagree most. Quaest and Datafolha suggest that only 37–40% of the eliminated candidates’ voters who chose a finalist chose Lula, versus 50% in our ballot-box estimate. Blending the two gives 45–51%. We’d describe the finding as “somewhere between an even split and a modest tilt to Flávio”, not as a certainty. More on this below.

Candidate by candidate

The table below is the whole story in one place: each row is a group of first-round voters, each column a second-round choice. A few things stand out: Cury’s voters leaned to Lula (52% versus 35%); Caiado’s leaned to Flávio (50% versus 35%); and Renan Santos’s were split, with a notable 12% voting null.

The full transition table

Read across: of everyone who did X in round 1 (row), what share did Y in round 2 (column)?

Darker blue = larger share. Numbers are model estimates, not counts of individuals.

Place by place

The country is not one electorate. Among the eliminated candidates’ voters, those in the Northeast leaned to Lula (54% of those choosing a finalist), while those in the South leaned to Flávio (only 41% for Lula). The comeback of first-round non-voters was also uneven: about 26% of them voted in the Northeast, against 17% in the North.

Place by place

Each tile is a state, laid out roughly like the map of Brazil. Click one to select it everywhere.

Small states and the vote abroad rest on very few model areas, hence the hatched tiles.

Be careful with small places. The model learns from ballot boxes, and Amapá, Roraima, Acre and the vote abroad offer very few areas to learn from, so their numbers can look dramatic for no good reason.

How sure are we?

Not as sure as a first look at those clean charts suggests. There are three honest ways to measure what we don’t know.

1. What the totals alone allow

Even before any statistics, the official totals rule some things out. For example, you can’t send more voters from a ballot box to Lula than voted for Lula there. The grey bars below show that arithmetic-only range, and it is wide: the totals alone leave a lot open. The gold bar is a 95% range from re-running the analysis on resampled data.

Three kinds of “range” around each estimate

Share of each first-round group that ended up with the chosen destination.

Hard limits (arithmetic)95% range (resampling)

Grey: what is mathematically possible given only the official totals. Gold: 95% range from resampling the data. Dot: our best estimate.

2. Do the polls agree?

For the groups where we have poll data, the picture is mixed. Where the ballot-box method and the polls agree (Caiado’s voters, for instance) that’s reassuring. Where they differ, such as Renan Santos’s voters or the non-voters who returned, the polls have their own problems: they measure intentions before the vote, from small samples, relying on memory.

Ballot boxes versus opinion polls

Among people who chose Lula or Flávio, what share chose Lula? Four ways of answering.

Poll answerBallot boxes onlyBallots + polls (trusting polls)Ballots + polls (allowing poll bias)

Polls ask about intentions a few days before the vote; the ballot-box method looks at the actual result. Differences are informative, not a verdict.

3. Does the method work when we know the answer?

We built 1,000 artificial elections, using real ballot-box sizes but invented voter behavior, and asked the method to recover the truth. In friendly conditions it did well: about 1.3 of every 100 voters were put in the wrong box. But when voting habits depended on the surrounding make-up (the “neighborhood effect” from the toy example), the error jumped to about 11 of every 100, and the 95% range captured the truth only about 39% of the time.

Testing the method on simulated elections

We invented 1,000 elections where we know the truth, then asked the method to recover it.

Average share of voters placed in the wrong box

How often the “95% range” contained the truth (target: 95%)

The red bar is the scenario where voters’ habits vary with the make-up of their surroundings. Simulations use real ballot-box sizes but only five voter groups.
How to read this

Trust the broad strokes: loyalty of the finalists’ voters, the fact that returning non-voters and blank/null voters leaned to Lula, and the regional contrasts. Be wary of the decimals and of small groups. The 95% ranges are best read as a minimum amount of uncertainty.

What this is, and isn’t