This paper investigates whether judge political affiliation contributes to racial and gender disparities in sentencing using data on over 500,000 federal defendants linked to sentencing judge. Exploiting random case assignment, we find that Republican-appointed judges sentence black defendants...