Discount and specialty retailers have been among some of the best performers in the market over the past few years, but none has performed better than Ollie's Bargain Outlet Holdings (OLLI -0.48%), a retailer that flies under the radar of many investors.

With 285 stores in 22 states generating some $1.1 billion in sales, Ollie's is no slouch. But it trails well behind others in the space like Big Lots, Five Below, and the dollar-store chains Dollar General and Dollar Tree, each of which has hundreds or thousands more stores across the country.

OLLI Chart

OLLI data by YCharts.

Yet despite its smaller size, or maybe because of it, Ollie's has far outperformed its rivals since going public in 2015. It soared 42% on its first day of trading and pretty much hasn't looked back since.

A growth story

Like its peers, Ollie's offers extreme discounts on name-brand products -- including housewares, food, books, floor coverings, toys, and hardware -- in no-frills stores. And it provides a true treasure-hunt experience as it its inventory over every few days. At the same time, it gives Ollie's Army -- the nearly 9.3 million consumers who have signed up for the retailer's loyalty rewards program -- consistency by carrying trusted brands.

But there are some things you won't find at Ollie's, like clothing and footwear. Last year, CEO Mark Butler told analysts that apparel and footwear might only be bought "very selectively," but that's not where Ollie's focuses its efforts. "Our main business is hard goods," he said.

Ollie's Bargain Outlet store

Image source: Ollie's Bargain Outlet.

That selectivity seems to be working. Sales have grown at a nearly 19% annual compounded rate since 2013, rising from $504 million five years ago to $1.07 billion last year. Profits have done even better, surging from $19.5 million to $127.6 million, or a near-60% compounded growth rate.

While a lot of that growth has come as a result of expansion (Ollie's had 187 stores in 16 states at its IPO), there's more coming. Last week, Ollie's Bargain Outlet acquired 12 former Toys R Us stores for $42 million, which it aims to open over the course of 2019. Ollie's plans to open new stores in the mid-teens each year.

Equally important, Ollie's was acquiring the toys that Toys R Us was liquidating earlier this year. While Butler said the impact of the toys it sold wasn't notable in the first quarter, it's likely to play a bigger role during the Christmas shopping season. He sees it as a win for Ollie's after having bought the inventory cheap.

Butler points out that the retailer does this year in, year out: "It's toys this year, and it might have been hardware last year, and it might have been housewares last year. This is what we do."

Too good to last?

This highlights what has made Ollie's Bargain Outlet work so well over the past few years. As the retail industry has run into trouble, it created an environment that allowed the closeout variety store to make opportunistic purchases. The savings are passed along to Ollie's Army, and the profits have flowed to the bottom line. But, perhaps, some caution is warranted.

This past quarter saw retail make a remarkable rebound, with sales and earnings spiking higher at chains like Walmart, Macy's, and Kohl's. While that may be attributable to the improving economy, heightened consumer confidence, and corporate tax reform, it could signal a slowdown coming for Ollie's.

Whether the current retail environment is just a temporary bounce or a prolonged trend higher will determine whether Ollie's can continue getting the good deals to which it has become accustomed.

Paying up for quality

Ollie's stock isn't cheap now, either, trading at 41 times trailing earnings and 43 times next year's estimates. It's also going for more than four times sales and 60 times the free cash flow it produces.

The closeout retailer has made an amazing run and earned its best-of-breed title, but investors who are now discovering this growth story might want to be wary of buying in at these levels.