JB Straubel, Tesla Motors chief technical officer. Getty Images

When Tesla CEO Elon Musk announced on Wednesday that technology chief JB Straubel is leaving, any close follower of the electric carmaker knew it represented more than the departure of a typical CTO. In the first decade of Tesla's existence, Straubel, who's among the group of co-founders, invented or co-created many of the company's signature technologies. His name is on a majority of patents that Tesla filed, especially relating to electric vehicle batteries — safety, architecture, monitoring and power management. "JB is absolutely brilliant," said Gene Berdichevsky, employee No. 7 at Tesla, in an email. "When I started, we did some of the technical development in his garage! I think there would be no Tesla as it is today without JB." Straubel, who's now 43, lobbied early on for Tesla to pursue a supercharger strategy, instead of going down the road of battery-swapping. Today, that network of charging stations, available for Tesla drivers only, is a boon for the company because it can offer greater service to customers, while drivers of most other electric cars are relegated to compete for time at generic chargers. Musk delivered the news of Straubel's exit this week while issuing some disappointing financial results to Wall Street. It was tough timing for a company that's struggling to find a profitable model for building and selling cars as it's investing in self-driving technology. Tesla recorded a quarterly loss of $408 million, and its automotive margins eroded as customers showed a clear preference for the lower-priced Model 3 sedans. Drew Baglino, who Straubel recruited to Tesla in 2006 and was most recently vice president of technology, is now stepping into the role of CTO. The Straubel announcement coupled with the weaker-than-expected results pushed the stock down 14% on Thursday, marking the steepest drop of the year. A Tesla spokesperson didn't respond to a request for comment.

Jeffrey Straubel, chief technical officer and co-founder of Tesla Motors Inc., center, speaks as billionaire Elon Musk, chief executive officer of Tesla Motors Inc., left, and Yoshihiko Yamada, consultant at Panasonic Corp., look on during a press event at Tesla's new Gigafactory in Sparks, Nevada, U.S., on Tuesday, July 26, 2016. Troy Harvey | Bloomberg | Getty Images

Musk and Straubel met in 2003, when Straubel intended to pitch him on the idea of building an electric airplane. But their shared passion for electric vehicles led Musk to introduce Straubel to Tesla's founders, Martin Eberhard and Marc Tarpenning. Musk backed Tesla and joined the board in 2004, a month after Straubel joined, and became CEO in 2008. In discussing Straubel on the earnings call, Musk said, "if we hadn't had lunch in 2003, Tesla wouldn't exist basically." Even before his Tesla days, Straubel was working on electric cars. Berdichevsky, who is now CEO of Sila Nanotechnologies, said he knew Straubel back when he was converting a classic Porsche into an electric vehicle. He also built and raced solar cars on a team at Stanford. He "was always a true missionary and visionary for EVs well before the world truly cared," Berdichevsky said. More recent Tesla employees describe Straubel as well-respected and a gentler voice in the room next to the bombastic and outspoken Musk. He's an engineer at heart, a licensed pilot and father who wears khakis most of the time. His obsession was always to reduce costs per kilowatt hour — to make energy-dense vehicle batteries at a lower cost. Straubel's focus at Tesla was on building technology, teams and partnerships, and he was more than willing to cede the limelight to Musk, one reason the two got along so well, former employees said. He split his time between Tesla's car assembly plant and offices in California and the Gigafactory, which he helped plan and build in Sparks, Nevada. He practically lived in trailers amid the rocks, dirt and construction materials until the massive battery plant was up and running in 2016, according to people familiar with the matter. At Straubel's urging, Tesla built charging capabilities into the Model S, before the Supercharger network was developed. He led propulsion and software teams through the development of the Model S and Model X. He also led the development of stationary energy products even before Tesla acquired SolarCity. Today, Tesla's Powerwall and Powerpack function as home batteries and utility-scale battery installations that make it possible to store and use solar and wind power.

Tesla cars at charging stations in Beijing, China. Meghan Reeder | CNBC