Official data from Spain's Ministry of the Interior, INE and BOE

Guide · Electoral system

The D'Hondt method, explained with real data

How votes become the 350 seats of Spain's Congress, step by step, with the example in the law itself, a simulator and the seats decided by the fewest votes since 1977.

Pediment of the Congress of Deputies in Madrid

First, how many deputies each province elects

The Congress has 350 deputies. Each province starts with 2, and Ceuta and Melilla elect 1 each. The remaining 248 are shared among the provinces by population (LOREG, art. 162). For 29 November this is set by Real Decreto 806/2026: Madrid elects 38, Barcelona 32, eight provinces such as Teruel and Ávila elect 3, and Soria 2.

So the D'Hondt method is applied 52 times, once in each constituency. The 29N election page lists the deputies for every province.

The rules in article 163

  • Lists that do not reach 3 % of the valid votes in the constituency are left out. Blank votes are valid, so they count towards that threshold.
  • The remaining lists are ranked by votes, highest first.
  • Each list's votes are divided by 1, 2, 3… up to the number of seats in the province.
  • Seats go to the highest quotients, in descending order.
  • If two quotients tie, the seat goes to the list with more votes; if they also tie on votes, it is decided by lot.
  • Within each list, seats go to candidates in the order they appear.

The example in the law itself

The LOREG includes a worked example: 480,000 valid votes, 8 deputies and six lists: A 168,000 votes, B 104,000, C 72,000, D 64,000, E 40,000 and F 32,000. All pass the 3 % threshold (14,400 votes).

The eight highest quotients are 168,000 (A÷1), 104,000 (B÷1), 84,000 (A÷2), 72,000 (C÷1), 64,000 (D÷1), 56,000 (A÷3), 52,000 (B÷2) and 42,000 (A÷4). Result: A wins 4 seats, B 2, C 1 and D 1. E and F win nothing even though together they have 15 % of the vote.

The quotients of the example in the law, highest first: the top eight win a seat168A÷11104B÷1284A÷2372C÷1464D÷1556A÷3652B÷2742A÷4840E÷136C÷234.7B÷333.6A÷532D÷2↑ 8 seatsno seatQuotients in thousands of votes. The number in each bar is the order in which the seat is allocated.
Example from article 163 of the LOREG. E misses out: its quotient (40,000) falls short of the 42,000 with which A wins the last seat.

The simulator below starts with the same example. Change the votes, the seats or the threshold and see how the result changes.

Simulator

ListVotes%Seats
——
——
——
——
——
——
——
——

Quotients: shaded cells win a seat

Why the size of the province matters

In a province that elects 3 deputies, a list may need more than 20 % of the vote to win one; in Madrid, with 38, it needs far less. The legal 3 % threshold can only make a difference in the largest constituencies, such as Madrid or Barcelona: elsewhere the allocation itself demands a higher share to win the first seat.

And every province has at least 2 deputies however small its population. As a result a vote does not weigh the same everywhere: on 29 November there are 35,417 voters per deputy in Teruel and 145,708 in Madrid.

The seats decided by the fewest votes

Recalculating the allocation with the official votes of all 16 Congress elections since 1977, these are the last seats where the runner-up came closest to taking it.

The 10 closest last seats in Congress elections since 1977 (province pages in Spanish)
ElectionConstituencyLast seatRunner-upVotes short
1977LleidaPDPCPSUC-PCE35
Apr 2019ZaragozaPSOECs54
1979CórdobaUCDPSA-PA86
1982SoriaUCDAP-PDP87
1989NavarraUPN-PPHB107
1989MurciaPSOEIU117
1979NavarraUCDPSOE136
Nov 2019HuelvaPSOEPODEMOS-IU LV CA164
1979TarragonaCC-UCDCIU172
Nov 2019MelillaPPCpM182

Our calculation from the official votes published by the Ministry of the Interior: the extra votes the runner-up would have needed to take the last seat.

And the Senate?

The Senate does not use D'Hondt. Each voter ticks up to 3 names in the provinces and the four candidates with the most votes are elected; on the islands and in Ceuta and Melilla the numbers are smaller (LOREG, art. 166). 209 senators are elected this way on 29 November.

Frequently asked questions

What is the D'Hondt method?

A way of sharing seats among lists in proportion to their votes: each list's votes are divided by 1, 2, 3… and the seats go to the highest results. In Spain it is set by article 163 of the LOREG for the Congress.

Is the 3 % threshold national or per province?

Per province: it is calculated on the valid votes in each constituency, blank votes included (LOREG, art. 163.1.a).

Do blank votes help the big parties?

Blank votes are not given to anyone, but they raise the number of valid votes and with it the number of votes needed to reach 3 %. In practice this can only matter in Madrid and Barcelona.

What happens if two parties tie on the last quotient?

The seat goes to the list with more votes in total. If they also tie on votes, it is decided by lot (LOREG, art. 163.1.d).

Why can a party with more votes nationally win fewer seats than another?

Because seats are allocated province by province. A party whose vote is concentrated in a few provinces can win more seats per vote than one whose vote is spread across the country.

Sources: LOREG (consolidated text in the BOE), arts. 162, 163 and 166; Real Decreto 806/2026; official results from the Spanish Ministry of the Interior 1977-2023; voters: INE. Last reviewed: 22 November 2026.