"Heroin" is derived from the Greek “heros”, the same word that the words “hero” and “heroine” come from. The original Greek word referred to characters in Greek folklore who were demigods (half-god, half-human). It’s unknown why the Bayer company decided to name their drug this, though perhaps it comes from the drug's euphoric effect that can make its users feel superhuman.
When heroin was first produced by the Bayer Company in Germany in 1895 the drug was marketed as a safe, nonaddictive alternative to morphine. Free samples of heroin were offered to recovering morphine addicts. It turns out that heroin is actually even more potent than morphine. The sale of the drug was finally banned in the U.S. in 1923, and its possession and manufacture were banned in 1924.
PBS and HeroinAddiction.com both have interesting timelines cataloging the unusual history of heroin.