In the 2013 election, Idris vacated his federal parliamentary seat to contest the seat of Sungai Udang in the Malacca State Legislative Assembly. The move was far from a demotion: it was carried out by the Barisan Nasional coalition to install him as the Chief Minister of Malacca, replacing Mohd Ali Rustam. The coalition retained its majority in the state assembly and Idris was sworn in as Malacca's tenth Chief Minister.
