During the Middle Ages, major transportation methods of land were horses.
During the journey, you had to change the horseshoe, the horseshoe, but you cant find the horse shop conveniently.
So travelers visiting farmers, merchants and general homes and asking them "want to give horseshoes" and pass money and things for the cost.
After that, the people who have experienced this business had had to place their horseshoe in the front of the house and eaves to respond to the exchange.
As such, the story "When you hang the horseshoe, people and things come together and become happy, seemed to become a way of "horseshoe" as a present lucky charm.
(There are many other theories for origin.) )