China-based electronics maker Huawei, not so long ago considered the red-headed stepchild of the smartphone industry, is on the rise. It’s rumored to launch a Nexus smartphone later this year, managed to top revenue of $46.5 billion last year, and has now displaced Microsoft’s Nokia division to become the world’s third-largest mobile phone vendor.

And that gap isn’t even close. According to research firm Strategy Analytics, Huawei shipped about 3 million more phones than Microsoft, or 30.6 million versus the Redmond company’s 27.8 million. That’s a 50 percent uptick from last year for the Chinese company, and the resulting market share — 7 percent — encroaches on Apple (10 percent) territory. (For point of reference, Samsung sits comfortably in the lead with a 20.5 percent share.) Impressively, Huawei managed to fend of Chinese competitor Xiaomi, which saw shipments and marketshare grow to 4.6 percent (from 3.5 percent) and 19.8 million (up from 15.1 million) respectively.

Huawei’s performance is all the more impressive given the weak demand the industry faces. Samsung in particular has struggled — the South Korean giant’s smartphone shipments plummeted from 95.3 million to 89 million, a decline reflected in a seventh straight drop in the company’s quarterly earnings. “Global mobile phone shipments grew a lackluster 2 percent annually from 428 million units in [Q2 3014] to 434.6 million in [Q2 2015],” said Strategy Analytics director Woody Oh, which he attributed to “slowing demand” for handsets in Europe, China, and the U.S. “[It’s] the industry’s weakest performance for two years.”

Huawei has blockbuster devices to thank for its second-quarter success — its smartphones are especially popular in China, Strategy Analytics director Ken Hyers said in a statement — but the gains are mostly at Microsoft’s expense. Lukewarm reception of the Redmond company’s Lumia devices, a lineup it inherited in its 2014 purchase of Finnish company Nokia, led to a 5.5 percent slide in market share to 6.4 percent and a global place in fourth. It still managed handset shipments of 27.8 million, but that’s a far cry from the 50.3 million it sold a year earlier.

As Microsoft winds down its phone business in response (the company slashed 7,800 jobs from its Nokia division and wrote off $7.6 billion in costs related to the acquisition), Huawei is gearing up for a stateside push. Zhiqiang Xu, president of Huawei’s U.S. division, said the company would continue to add unlocked, unsubsidized devices to its online store throughout the year and offer benefits like a two-year warranty, free shipping for replacement devices, and U.S.-based call centers. “[The U.S. is] critical for Huawei,” Zhiqiang said in a recent interview.