Last year, the gym membership platform ClassPass become a unicorn, hitting a $1 billion valuation after it closed a $285 million Series E funding. The startup, which launched in 2013, saw rapid growth from the start, reaching an annualized $150 million revenue run rate in just three years. But the startup that came to know success very quickly first got to know failure very closely. 

Before Payal Kadakia founded ClassPass, she founded Classtivity--a brand that most have never heard of and for good reason. It was a flop. 

ClassPass, like its predecessor, Classtivity, is a platform where users purchase passes for fitness classes that they can use at any of the ClassPass partner facilities. In other words, rather than buying a membership to one particular gym, yoga center, or dance studio, people buy packages of classes from ClassPass, which they can use at all of the participating businesses. 

Kadakia's vision for the startup was born out of her own desire, as a passionate dancer. But before she decided to go all in and leave her corporate job in pursuit of the vision she saw value in, she confirmed that it was an idea that the market, too, saw value in, by doing her own market research. In doing so, she was met with so much interest that she received investment offers. 

And yet, upon the launch of Classtivity, the first version of what is now ClassPass, it was a failure. Her reality was every founder's nightmare: No one was using it. And it wasn't that no one was on the platform, it was that no one was going to class. 

In a desperate attempt to urge users to actually use--rather than simply peruse--the platform, the team at Classtivity decided to eliminate the financial barrier to entry and offered users to try a class for free. And still, they got nothing. 

When no one would even be willing to take classes for free, Kadakia realized she had hit rock bottom. She came to understand that there was fear or anxiety around whether to try a new fitness class. And even once the decision was made, people were then faced with hurdle after hurdle, or as she calls them "brain cycles." From having to pay for the class to having to input all the information to register for the class, it was more than users were willing to do. 

To combat these hurdles and eliminate these "brain cycles," she did what her team, until then, hadn't been willing to do. For the first time, after about a year and a half post-launch, they finally went and talked to their class partners, such as the gyms, fitness centers, and studios. Kadakia says they initially sort of hid behind the technology, thinking that they could just build a screen and people would book. 

Kadakia went on to say that when building a customer-oriented business, you need to understand both sides of the marketplace. And that "if you can't fix a behavior in real life, the chance of being able to do it via technology is zero."  

By going to the businesses, and later to the consumers, they realized that their product, which was originally designed to have people go and try 10 classes at facilities in their area over a 30-day period, had a fatal flaw. It only gave people what they wanted for one month. 

It had banked on the idea that people would find a favorite place to take classes, and that after Classtivity enabled them to find it, they would start buying classes directly from that business. But people didn't want to commit to classes from just one business. They chose ClassPass because of the freedom it afforded them to take classes anywhere. In other words, people didn't choose ClassPass to discover which gym they like the most but to be able to use any gym. 

While this was initially to the detriment of the struggling business, through this understanding, it recreated its business model and became a subscription-based product. In doing so, it began offering people what they really wanted, leading to the creation of a startup that earned $150 million in annual revenue in its third year, and became a unicorn with a $1 billion valuation in its seventh. 

In the words of Kadakia, "Don't let the process of hitting rock bottom take up too much time." The sooner you hit rock bottom, the sooner you can position your startup for success. 

It is within these failures that light is shone on what doesn't work, creating a stark contrast to what does. In the case of ClassPass--like many startups--the key to success wasn't simply in market validation, but in discovering its true product-market fit--something that often involves the guidance of failure, so long as you're willing to let failure guide you on your path to success.