Rajan received 20,392 votes and restricted Prachanda to 12,852 in his Kathmandu Constituency 10.
Third candidate CPN-UML's Surendra Manandhar received 13,615 votes.
Prachanda had won from the same constituency in 2008 with big margin. Rajan was his nearest rival then. Prachanda is also candidate from Siraha Constituency 5 also, where he is leading the vote count so far.
His party earlier demanded a suspension of the vote counting, alleging conspiracy after initial results showed the party trailing at third position in the elections.
Meanwhile, Chief Election Commissioner Neel Kantha Uprety told a press conference today that the counting was being carried out in "a transparent manner" and would continue.
"The elections were conducted in a free, fair and fearless manner, so the results must be accepted by all." He also asked the political parties to honour the peoples' verdict expressed through secret voting procedures.
The counting will lead to the formation of a 601-member assembly to draft a new Constitution, including 240 elected under a direct voting system.
There was proportionate voting for 335 seats and the remaining 26 members will be nominated by the government. In the previous Constituent Assembly elections in 2008, UCPN-M had emerged as the largest party with NC and CPN UML in second and third place.
Photos: Kareena Kapoor Khan and Aamir Khan at Mumbai airport
Photos: SRK, wife Gauri, Aishwarya Rai, Shweta Bachchan at Vogue Awards
Photos: Harbhajan Singh-Geeta Basra's TV outing with daughter Hinaya
Photos: Malaika Arora flaunts ripped jeans like a boss!
Photos: Vaani Kapoor, Kriti Sanon, Dia Mirza sizzle on the ramp