Chile's Senate has voted to end a dictatorship-era electoral system that has squeezed out independent candidates and guaranteed an outsized presence in Congress for the center-right and center-left blocs.

The "binominal" system has been in place since the end of the 17-year dictatorship of Gen. Augusto Pinochet in 1990, but this is the first time there are enough votes in Congress to end it. Senators approved the measure early Wednesday 24-3 with the key support of three center-right lawmakers after a debate that lasted more than 21 hours.

It had already been approved by the lower house and will now be reviewed by a joint commission before taking effect for the 2017 midterm elections.

The current system distorts the vote by giving one of the two seats in each district to the trailing coalition as long as it gets at least a third of the votes.

In practice, that has meant many elections are decided behind closed doors, with the center-left and center-right blocs hand-picking candidates to ensure neither side will get its way in Congress. President Michelle Bachelet had promised to finally end it calling the system a "thorn pounded into the center" of Chilean democracy.

"The change of the binominal system is without a doubt, a great advancement," Bachelet said after the vote. "It will allow us to be better represented and have better ideas" in Congress.

The new system essentially allots seats to parties by the proportion of votes they receive in each district.

The reform also increases the size of the lower house to 155 from 120, and the Senate to 50 seats from the current 38. As of the next legislative election, women must represent at least 40 percent of the candidates running for a party.

Senate President Isabel Allende said the reform will allow for more competition and avoid a predetermined result. "As a result, we're widening democracy," said Allende, the daughter of the late President Salvador Allende, who was ousted in 1973 during a military coup that launched the dictatorship.