In the summer of 2004, Dafchev signed for his previously team Lokomotiv Sofia. On 10 August 2006, he scored his first ever European goal, netting a free-kick against Bnei Yehuda Tel Aviv in a 2–0 away win. On 14 September, Dafchev scored free-kick and in a 2–2 home draw against Feyenoord. The following 2007–08 season he netted his third European goal in a 3–1 home win over Oţelul Galaţi of the UEFA Cup on 16 August 2007. In a 3–1 league win over Pirin Blagoevgrad on 11 November 2007, Dafchev scored his 49th and 50th goals in all competitions for Lokomotiv.