Xiaomi was once hailed as an Apple AAPL

Now, the company's founder admits that he "pushed ahead too fast."

"We created a miracle," Lei Jun wrote in a note to employees posted this week to Facebook and WeChat. He said the company now needs to slow down to "ensure sustainable growth for a long-term future."

In 2014, Xiaomi looked like a Chinese miracle. With smartphone sales topping 60 million and a valuation of $45 billion, the Beijing-based private firm was knocking on Apple's door.

But brand loyalty is a fickle thing in China's fiercely competitive smartphone market. Domestic rivals Huawei, Oppo and Vivo soon surpassed Xiaomi in smartphone sales, and by early last year analysts were flagging concerns about the company's decline.

Lei acknowledged in his note that Xiaomi faced "unforgettable" challenges, including four months of supply chain "issues" last year.

Related: These smartphone makers are beating Apple in China

Xiaomi made its mark by selling cheap smartphones directly to consumers online. The company touted blockbuster sales numbers, and even set a Guinness World Record in 2015 for the most mobile phones sold in a 24-hour period.

But selling millions of inexpensive phones yielded low profits and alienated high-end buyers.

"The brand was associated with being cheap, with working class [consumers] or students," said Nicole Peng, an analyst with market researcher Canalys. "For people who have money to spend, they won't chose Xiaomi because it's not chic."

Related: Apple gets bump from Trump and Samsung's woes

Lei admitted that selling cheap phones online isn't enough. He said the company will now focus on "innovative technologies and products that speak for themselves." The CEO also hailed the firm's recent "breakthrough in the high-end smartphone market" -- a reference to the bevel-free Mi Max, which Xiaomi released late last year to positive reviews.

The company will also beef up its offline retail presence, more than tripling the number of its brick and mortar Mi Home stores in the next year. Xiaomi currently has 54 Mi Home outlets, three of which topped 100 million yuan ($14.4 million) in sales last year, according to Lei.

The stores sell Xiaomi-branded devices like air purifiers, smart televisions, fitness trackers and even body weight scales.

Lei's public admission mirrors a move from fellow Chinese CEO Jia Yueting, who posted a public memo in November acknowledging that his company LeEco had "blindly sped ahead, overextended our global strategy and spent recklessly."

-- An earlier version of this story misstated Xiaomi CEO Lei Jun's name.