Can the judiciary help root out government corruption? This paper exploits the random assignment of court cases to justices who exhibit varying degrees of strictness to examine how convicting corrupt officials affects local government outcomes in the Philippines. I document that convictions improve the management of local public finances and reduce associated corruption. An exploration of mechanisms suggests that legal deterrence effects contribute to these findings. The results further indicate that convictions are effective at stifling corruption among bureaucrats, but not politicians. Consistent with this heterogeneity, convictions reduce electoral competition and consequently weaken accountability for incumbent politicians.