Because movies like Toy Story, Finding Nemo, and Monsters, Inc., are now considered modern-day classics, it’s hard to remember just how turbulent Pixar’s first years were. But when Lawrence Levy was recruited by Pixar chief Steve Jobs in 1994, the animation studio was bleeding cash. Unique structural challenges seemed to block any easy avenue to taking the company public, and a skeptical staff eyed their enigmatic boss with mistrust and resentment. In what reads like an IPO thriller, Levy, who served as the struggling company’s chief financial officer, details both his professional and personal journey in To Pixar and Beyond: My Unlikely Journey with Steve Jobs to Make Entertainment History.

“One of the reasons I wrote the book was that we’ve probably forgotten this story even at Pixar,” Levy said. “I wanted to do my best to capture it as it was.”

Pixar’s early years were defined by deep uncertainty, the frustrations and whims of its by then legendary boss, and the boundless creativity of its committed if alienated team. While the public perception of Jobs has softened somewhat since his death, Levy reveals a side of the tech innovator few saw, a side that current Pixar chief Ed Catmull says “the public missed entirely.” Following failures, Catmull told Fortune magazine, it was a transformed and more collaborative Jobs who led Apple to its dizzying success, not the hard-driving, top-down tyrant of popular imagination.

Levy concurs. “I thought it was very important to document this passage of time in his life,” he said. “One of the things that surprises people was how collaborative the working relationship was. Steve Jobs had a reputation for leading from the top, so this was a very different kind of relationship that came out of constant collaboration. I think that was a really important part of Pixar and Steve Jobs’s story.”

While Jobs and Levy developed a strong bond during their Pixar years, Levy still felt that something was missing in both his career and his spiritual life. “I was always interested in philosophy and religion. But I never had time with my career and family to explore it in a deep way,” he explained. “Eventually, I thought ‘I want to explore this. I don’t want to keep ignoring this.’”

After Levy paved the way to a public offering that was as successful as it was unlikely, his spiritual longing led him to make one of the most momentous decisions of his career. Six years after Pixar’s initial public offering and the box-office-busting success of Toy Story, Levy decided to leave his role as CFO (though he remained on Pixar’s board for the next seven years) to start what would later become the Juniper Foundation, a Silicon Valley nonprofit devoted to making the essence of Buddhist teachings and practices accessible to contemporary seekers. One of the most poignant exchanges in Levy’s book comes when, after a long and fruitful partnership, the author describes the moment he told Jobs he was resigning to pursue his spiritual aspirations: “I’m glad one of us is doing it,” Jobs responded.

“He had a lot of respect for what I was doing,” Levy recalled. “He had respect for and an understanding of Eastern philosophy. We used to talk about that kind of thing often and about the challenges I would take on for doing it.”

Though Jobs was supportive of Levy’s decision, many of his other tech colleagues were bewildered by his career shift. “People were surprised, and I myself was surprised that this is what I wanted to do,” Levy said. “At the time, I was thinking, ‘This seems a little crazy,’ but it was something that I needed to do.”

Working alongside his wife, Hillary, Levy began looking into different spiritual traditions and brainstorming about how to bring meditation into hectic communities like Silicon Valley. “I began to gravitate toward Buddhist ideas,” Levy said. “I saw it not as an ideology but as a methodology to find truth.”

One of the Juniper Foundation’s first official goals was to contemplate how to bring ancient Buddhist teachings to a contemporary Western audience. “The deeper I got into it the more strongly I felt that wherever these teachings had taken root, they’d been adapted to the local culture and norms,” Levy explained.

Though the Juniper Foundation was thriving, it wasn’t until Levy was in a harrowing car crash nearly three years ago that that he saw a connection between Pixar’s success and the Middle Way—the Buddha’s teaching about discovering insight and wellbeing through avoiding extremes. During the weeks of his recovery, he says, he started to realize how the tale of Pixar’s historical rise could be effectively used to illustrate how true success is not possible unless it comes from a compassionate place. The idea found its way into talks he began to give around the country: “I use Pixar as a metaphor to illustrate that point,” Levy said. “Pixar was a creative force that needed a bureaucratic force to succeed.”

Levy says listeners began to ask to know more about his experience and career path. While he knows that not everyone can walk away from their careers to work for nonprofits devoted to meditation, he says there are small steps everyone can take to make their day-to-day lives more meaningful.

“If we want to overcome our anxiety and feel good about ourselves, it’s not enough to invest in outer things,” Levy noted. “We have to make investments in our inner life as well. It doesn’t have to take a lot—that something could be a five-to-10 minute meditation practice every day and slowly absorbing the ideas associated with it. It’s not about the time, it’s about keeping grounded and having perspective. It’s never too late to open that door.”

To Pixar and Beyond: My Unlikely Journey with Steve Jobs to Make Entertainment History by Lawrence Levy is available from Houghton Mifflin Harcourt on November 1.