The incident took place at Jaito Sarja village under Ranger Nangal police station last evening.
SHO Paramjit Singh said the girl's grandfather had lodged a complaint that the girl, a student of Class III, was lured by a youth of the same village.
The youth allegedly lured the girl who had gone to a shop to buy toffee. The accused, Charanjit Singh, then took her to a lonely place where he made an attempt to rape her.
However, as the girl started crying out loudly he fled leaving her behind. The victim later narrated the incident to her family. Police have registered a case against the accused, who was absconding.