Harry Potter discovered it in the potions book which belonged to the Half-Blood Prince in Harry Potter and the Half-Blood Prince, his sixth year at Hogwarts. Later, when Snape was escaping Hogwarts after killing Albus Dumbledore, Harry tried to use it on him, but he managed to block it, revealing himself as the Half-Blood Prince, and creator of the spell. It has since been used many times by many characters.
In the film version of Harry Potter and the Order of the Phoenix, Harry is shown teaching this spell to members of Dumbledore's Army, despite learning it a year later in the books. The effects of the spell are also different: instead of hanging by their ankles, the person on which the spell is being cast is simply levitated or blasted into in the air, apparently depending on the force used.