He defeated the incumbent Danilo Türk in a runoff election held on 2 December 2012, receiving roughly two-thirds of the vote.
He rose to prominence in the late 1980s, when he became one of the strongest supporters of the reformist wing of the Communist Party, led by Milan Kučan and Ciril Ribičič.
The same year, he was appointed to the Central Committee of the League of Communists of Slovenia, thus becoming the youngest member of this body in its history.
Instead, the Liberal Democracy of Slovenia formed a coalition with the conservative Slovenian People's Party, based on a centrist platform, which ruled until 2000.
During this period, he distinguished himself with a moderate and non-partisan behaviour, which gained him the respect of large sectors of the centre-right opposition.
As the speaker of the parliament, he pushed for a public commemoration in the memory of the deceased anti-communist dissident Jože Pučnik, which was initially opposed by the more radical members of the ruling left wing coalition.
Throughout the 1990s and 2000s, Pahor remained an outspoken supporter of Slovenia's entry in this military alliance, which was opposed by several left-wing sectors of the society.
[11] He served on Parliament's Budgetary Control committee and the Constitutional Committee during the period of the rejection of the Constitutional treaty by France and the Netherlands and the negotiation of the Lisbon Treaty, supporting the Parliament's line on this (Richard Corbett and Inigo Mendez de Vigo report).
In October 2004, the centre-left coalition in Slovenia lost to the liberal-conservative Slovenian Democratic Party and its conservative allies.
In 2006, Pahor's Social Democrats entered an agreement with the ruling coalition party for the collaboration in the economic reform policies.
However, due to the high ranking of his party, he decided to support the presidential candidate Danilo Türk, and continue to lead the Social Democrats to the parliamentary elections of 2008.
[14] The voters voted in favour of an arbitration agreement with Croatia, aimed to solve the border dispute between the countries, emerging after the breakup of Yugoslavia.
[14] Tensions between the coalition partners reached the summit in 2011, when two parties, DeSUS in April and Zares in July, left the government.
[15] Faced with the loss of several ministers and falling public support, Pahor asked the Parliament for a motion of confidence.
[19] On 1 December 2011, several clips of the recordings of closed sessions of the Government of Slovenia during Borut Pahor's term were published on the video-sharing website YouTube.
[26] In September, the Civic List, a centrist party in the Slovenian center-right government coalition, also officially supported Pahor's candidacy for president.
He also met Vladimir Putin, whom he encouraged to try to resolve the Ukrainian conflict, and suggested a Trump-Putin meeting in Ljubljana, which has previously served as a venue for such occasion in 2001.