Were you unable to attend Transform 2022? Check out all of the summit sessions in our on-demand library now! Watch here.

Yelp’s 5 years as a public company have not always been fun. Founded almost 13 years ago, the social review site hit a low point in May 2015 with rumors that it was seeking a buyer as growth sputtered.

Despite being a Web 2.0 pioneer, it has only occasionally managed to post quarterly profits. It’s seen its stock fall sharply from its most optimistic moments, when it hit $97.25 per share in 2014. In February 2016, it fell as low as $15.56 per share.

But just as it seemed time to start preparing the obituaries and post-mortems, Yelp has returned from the near-dead.

Yesterday, the company released its second quarter earnings showing that revenue grew 20 percent in the quarter from the same period a year ago. And it posted profits of $7.6 million.

Investors were thrilled. Yelp’s stock exploded 27.64 percent to close at $40.04 per share.

There were several developments from Yelp that drove this giddiness. But in general, the company seems to have pulled off a remarkable trick: It’s growing by shrinking.

Over the past year, a company that has sometimes had a history of messy operational issues has developed a newfound sense of discipline and decisiveness. The biggest move it made was deciding to exit most of its international business.

Outside of the U.S. and Canada, Yelp was only making 1 percent of its revenue from international markets by the end of 2016. So the company made a tough call: Exit the international businesses and cut 175 employees.

In narrowing its focus, the company invested in expanding the company’s U.S. sales force, which paid off with big growth in signing up new companies and holding on to those who were already customers. In addition, Yelp said yesterday that it is opening a new office in Washington, D.C.

The company also took steps to address declining traffic to its mobile apps. And as part of the parade of good news yesterday, the company said it was selling its Eat24 delivery business to Grubhub.

Narrowing its ambitions, pulling the plug on being a global company for now, might have seemed like a desperate retreat last year. Instead, it’s resulted in faster growth in its core market.

Yelp’s challenge now is to continue to expand on that momentum. As executives noted in a conference call yesterday, restaurants are still the largest portion of its revenues. It’s trying to leverage that with new services, but also by trying to convince users who come for restaurant reviews to explore other categories.

That will still be a challenge. But this new Yelp has regained a lot of credibility with investors who are ready to believe again.

VentureBeat's mission is to be a digital town square for technical decision-makers to gain knowledge about transformative enterprise technology and transact. Discover our Briefings.