PARIS — A Danish pharmaceutical company said Friday that it would stop shipping a powerful drug to American prisons that carry out the death penalty by lethal injection because some states began using it as a substitute for another compound that was taken off the market.

The company, Lundbeck, said in a statement that it “adamantly opposes the distressing misuse of our product in capital punishment.” Lundbeck informed its distributors that from now on its sodium pentobarbital injection, a barbiturate sold under the brand name Nembutal, would be available in states that conduct lethal-injection executions on only a restricted basis.

“After much consideration, we have determined that a restricted distribution system is the most meaningful means through which we can restrict the misuse of Nembutal,” Ulf Wiinberg, Lundbeck’s chief executive, said in the statement. “While the company has never sold the product directly to prisons and therefore can’t make guarantees, we are confident that our new distribution program will play a substantial role in restricting prisons’ access to Nembutal for misuse as part of lethal injection.”

The death penalty is prohibited throughout the 27-member European Union, and human rights groups have brought pressure on drugmakers not to supply lethal drugs for American executions.