Turkey's constitutional court on Friday overturned sections of a controversial reform tightening the government's grip on the judiciary, local media said.
The court said the most controversial clause of the law, giving the justice ministry greater control over the appointment of prosecutors and judges, was unconstitutional, private NTV television reported.
The decision came after an appeal by a lawmaker from the main opposition Republican People's Party (CHP).
The court also overturned parts of the law that give the justice minister the authority to investigate prosecutors of the Supreme Board of Judges and Prosecutors (HSYK), an independent body responsible for appointing members of the judiciary.
The contentious bill, which sparked fistfights among lawmakers debating it in parliament, was signed into law by Turkish President Abdullah Gul in February despite opposition and rights groups arguing it was an attack on democracy.
The bill was one of the retaliatory measures taken by Prime Minister Recep Tayyip Erdogan in the wake of a graft scandal which erupted in mid-December implicating key allies of his.
The premier has accused Fethullah Gulen, a US-based Muslim cleric, and his loyalists in the Turkish police and justice system, of being behind the corruption probe.
The wide-ranging investigation posed the biggest challenge to Erdogan's 11-year rule and the government reacted by embarking on a mass purge of police and prosecutors believed to be close to Gulen's Hizmet movement.