With the deadline for the offer expiring at 8 a.m. ET, Mylan said just 40 percent of Perrigo's outstanding shares had been tendered, short of the required 50 percent.
The tendered shares will now be returned, Mylan said. Perrigo will aggressively buy back stock at the start of trading, sources told CNBC.
The failure ends nearly seven months of bitter wrangling between the generic drugmakers, and hands a big victory to Perrigo Chief Executive Joseph Papa.
Mylan Executive Chairman Robert Coury, who snubbed an takeover offer from Teva Pharmaceutical Industries Ltd to pursue Perrigo, said the company was ready to move on.
"We are well-positioned to quickly execute on the next strategic, value-enhancing opportunities for our business, some of which we have already identified," he said in a statement.
Mylan shares were up about 10 percent at $47.39 in premarket trading, while Perrigo's were down 9.3 percent at $141.99.
Mylan made its first public offer for Dublin-based Perrigo in April and pursued a hostile takeover when it was rejected.
Mylan's offer of $75 plus 2.3 Mylan shares was worth about $174.36 per share, based on Mylan's Thursday close of $43.20, or about $26 billion for all outstanding Perrigo shares.
Both companies have tied up with foreign companies in recent years to trim their tax bills and organize in Europe using a maneuver called an inversion. Mylan became part of a new company incorporated in the Netherlands but still runs its business out of its Canonsburg, Pennsylvania, near Pittsburgh. Allegan, Michigan-based Perrigo combined with Ireland's Elan Corp. and now lists its headquarters as Dublin.
The stock of both companies had fallen more than 10 percent since Mylan bypassed Perrigo's board and took its offer to shareholders.
—CNBC's David Faber and wires contributed to this report.