It's completely normal
Hamsters are coprophages (is that the right spelling? o.o), meaning they have poo as part of their natural diet. Rabbits, some species of pigs, and lots of varieties of insects are also coprophages.
Basically, since hamsters naturally have a rough foraging diet, high in difficult-to-digest plant matter, their digestive systems don't get all the nutrition out on the first go. So they eat it again to absorb as many nutrients as they possibly can. The dry pellets you normally see from hamsters are actually the second time it's passed through them.
This practice also helps introduce hindgut bacteria to their upper digestive systems, which is beneficial to the hamsters.
It's just how nature helps a hamster get as much nutrition out of a rough diet as it can.
You're not alone though; the first time I witnessed it I immediately freaked out, thinking there was surely something wrong if she was resorting to eating her own poo!
Nature: sometimes interesting, but always nauseating xD