The order overturns a change in the law by Sharif's ruling Pakistan Muslim League-Nawaz that allowed the former premier to lead the party despite being legally banned from holding public office.
"The Election Commission is directed to remove name of Nawaz Sharif as president of PML-N from all official records," Chief Justice Saqib Nisar said from the bench.