How we dug 21.co out of an $80 million hole, turned it into Earn.com, built it into a fast-growing business with millions in revenue, and sold it to Coinbase.

In May 2015, I became CEO of a company that was in a very difficult situation.

21.co had been started as 21E6, a bitcoin mining company with a sizable data center footprint and a monthly bill to match. The company was set up to return mined bitcoin to its shareholders and generated tens of millions in revenue during its first calendar year of operation. It had thus attracted a substantial amount of investment.

However, it had spent most of this capital on chips, hardware, and data center deployments. And when the Bitcoin hashrate soared and the price of BTC crashed over the course of 2014, the company landed up in a Loudcloud-like scenario with long-term data center leases and falling revenue. Many other mining companies around this time suffered similar fates and died, including Hashfast, Cointerra, Alydian, Aquifer, and others.

While I had helped 21E6 get started back in early 2013, I hadn’t been operationally involved. Instead, I was busy working full time at Andreessen Horowitz as a General Partner. However, once things went wrong, we realized that an advisory role wasn’t going to be sufficient. So I stepped in as full-time CEO with a mandate to fix things. We brought in Lily Liu as a new CFO, and we got to work.

The company we took over in May 2015 was in deep trouble. It had more than $80M in data center and venture debt commitments with less than a year of runway. It had announced a large capital raise, but that was a cumulative figure: the vast majority of the funds had been spent by previous management or locked up in contracts signed before our new team took over. Millions of dollars in bitcoin were being mined every month, but even more millions were being spent in obligate contracts. And to make matters worse, all the BTC returned to shareholders by the mining operation was in danger of being completely clawed back if the company entered a messy bankruptcy.

The new team thus had a very short period of time to do two things: find a way to exit these legacy contracts and figure out a new product — or end up with an $80M hole in the ground.

On the contract side, after an enormous amount of hard work we were able to exit all data center contracts, extinguish all debt, cut the burn by >90%, and extend the company’s runway to the next decade. Some day I’ll write the Hard Thing about Hard Things 2.0 about this process.

On the product side, we’d inherited a risky Hail Mary project called Bitsplit, which tried to salvage some value from the data centers by repurposing the datacenter’s mining chips to embed in phone chargers. Because a phone’s charger was not a power-constrained environment, the idea was that it could be used to power a distributed mining operation, generating a constant stream of BTC that could give every phone owner a free trial of cryptocurrency. We built the requisite software and a hardware development kit to show what this could look like, but by this time Bitcoin micropayments went from potentially feasible to definitely infeasible due to the scaling controversy.

Nevertheless, the open source software we built to handle micropayments ended up being the core of something that did work: namely the paid email and tasks product at the core of what is now Earn.com.

As of today, Earn.com is a fast-growing, cash-flow positive business with a multimillion dollar revenue run rate. Hundreds of thousands of users have signed up to earn free cryptocurrency by answering emails and completing tasks. And thousands of senders have used Earn.com to send out paid emails and surveys to large audiences. I think it’s fair to say that it’s one of the first truly useful blockchain-based applications, where users can earn money in their spare time while senders can pay people to actually reply to their emails and fill out their surveys.

Now we’re about to take the model we’ve proven out at Earn.com and scale it up across Coinbase’s massive user base. As part of this acquisition, I’ll be joining as Coinbase’s new CTO. And with this deal, the total value of cash, cryptocurrency, and equity returned to our shareholders is now in excess of the capital invested in the company.

I’m proud of what our team has accomplished, I’m proud of the fact that we turned what could have been a real problem into a successful product, and I’m excited about the road ahead.