tesla-googleThis story is excerpted and adapted from Elon Musk: Tesla, SpaceX, and the Quest for a Fantastic Future, due out May 19 from Ecco, an imprint of HarperCollins.

On May 8, 2013, Tesla Motors shocked just about everyone by posting its first-ever quarterly profit, reporting higher-than-expected demand for its Model S electric sedan. That moment marked the beginning of a turnaround for Elon Musk’s tumultuous automaker. The next year would see the Model S win most of the automotive industry’s major awards and Tesla’s share price rise roughly fivefold, to more than $200. The 2013 profit announcement was fortuitous. Just weeks before, Tesla had been on the verge of bankruptcy.

Earlier in 2013 the company was struggling to turn preorders of its vehicles into actual sales. As Musk put his staff on crisis footing to save Tesla, he also began negotiating a deal to sell the company to Google through his friend Larry Page, the search giant’s co-founder and chief executive officer, according to two people with direct knowledge of the deal. Tesla spokesman Ricardo Reyes and Google spokeswoman Rachel Whetstone declined to comment. “I don’t want to speculate on rumors,” Page said when I asked him if Google had considered buying Tesla, adding that a “car company is pretty far from what Google knows.”