The incident occurred last night in Yendagatla village under Nagarkurnool police station limits when the girl, a daily-wage labourer, was going to attend nature's call, they said.
Srisailam, Umapathi and Devraj, followed the girl and dragged her to bushes and one of them allegedly raped her, while two others gagged and bound her, police said.
After the girl raised an alarm some locals rushed to the spot even as the trio, who work as plumbers in the same village, fled from the scene, police said, adding that two of them were later taken into custody.