Amazon Business, which sells bulk items to business customers, scrapped the plan after considering it last year, according to people familiar with the matter.
Shares of McKesson and Cardinal Health both rose more than 3 percent, while AmerisourceBergen rose 2.2 percent. McKesson's stock has been relatively flat over the past year, while Cardinal's stock has slid 25 percent. AmerisourceBergen is off about 3 percent over the past year.
Distributors of pharmaceuticals and medical supplies have been viewed as being possibly the most vulnerable to Amazon's entry into health care. Amazon has mastered logistics and shipping for everyday products such as toilet paper and cleaning supplies, worrying some the company could do the same with drugs and medical supplies.
Others, however, have said those fears are overblown because the hurdles might be too high for even mighty Amazon to overcome.
Part of Amazon's decision comes from its inability to persuade hospitals to change their current purchasing practices and its need to build a more sophisticated logistics network, the people told CNBC.
— CNBC's Eugene Kim and Christina Farr contributed to this report.