As the lights of the strip ­glimmer below, Pandora co-founder/CEO Tim Westergren stands before two dozen advertising executives in a 61st floor suite in the Cosmopolitan of Las Vegas. It’s the first day of 2017’s Consumer Electronics Show (CES), and he’s pitching Pandora’s new direction. “In my opinion, the other music subscription products out there are unsatisfying,” he says, referring to the on-demand streaming services the new Pandora Premium will begin competing with later in 2017. “They give you millions of songs, a search box and ‘good f—ing luck.'"

Clad in his usual uniform -- button-down shirt, dad jeans, hiking sneakers -- the 51-year-old Westergren proposes that the ­solution lies in Pandora’s Music Genome Project, which enables the service to recommend songs based on 450 ­characteristics, plus the data Pandora has collected on listener preferences. Those assets will power Pandora Premium when it launches before the end of March, as they do the ­service’s free radio and ad-free $4.99-a-month Pandora Plus tiers.

Pandora dominates the U.S. online radio market with a staggering 78 ­million monthly users, 4.3 ­million of whom pay for Pandora Plus, and brought in $1.2 ­billion in revenue in 2015. But it’s only now about to enter the bruisingly competitive on-demand subscription market dominated by Spotify and lately disrupted by Apple Music and Amazon Music Unlimited. The talk of 2017’s CES? Amazon’s Alexa Voice Service, the software that enables voice ­control on ­compatible devices -- just as it allows Amazon Music Unlimited listeners to ask out loud for songs and playlists. And not long after the conference, Apple announced it would begin ­producing its own movies and shows exclusively for Apple Music subscribers, specifically to open up an advantage over Spotify.

Pandora Premium, explains Westergren, will combine the play-what-you-want flexibility of Spotify with “lean back” radio features that will appeal to casual fans. “Playing music that you’ve never heard but you love, that’s the goal for a music service,” he says. “If you can do that consistently, that’s all she wrote -- that’s a customer forever.”

Westergren, who studied political science and music at Stanford and spent his 20s playing keyboards in rock bands, believes that ­introducing users to new music also benefits developing acts. On some level, he has always wanted to build the kind of company that would have helped him when he was a ­gigging ­musician. While Spotify and Apple Music ­distinguish ­themselves with ­tastemaker playlists and A-list exclusives, Pandora has always emphasized how its algorithm positions unknown acts alongside the superstars. “There’s a genuine idealism about it all,” says Republic Records COO Avery Lipman. “I’ve had meetings with other services and I thought, ‘For God’s sakes, get someone with a ­tattoo and an earring in the room.'"

With just over 2,000 ­employees ­(excluding Ticketfly, which it bought in October), Pandora, which went public in 2011, is no scrappy startup. But it is ­streamlining: On Jan. 12, the company announced that it laid off 7 percent of its ­workforce. “There’s nothing ­positive about letting people go,” says Westergren the next day. “But we’re doing this the right way, and it’s a more focused company.”

As it seeks to convert 10 percent of an expected 110 ­million users to premium-tier subscribers by 2020 -- which would majorly boost its bottom line, even if it would still lag behind its ­competitors -- the ­service must reassure its ­stockholders. They include activist hedge fund Corvex Management, which owns a ­significant stake and in the past has pushed for a sale of the ­company. Pandora’s stock fell from a 2014 high of $37 to $13 on the day of Westergren’s Las Vegas ­presentation. The next morning, after a SiriusXM executive dismissed rumors of a takeover, the stock fell another 4 percent. The following week, in the wake of the layoffs but after Pandora announced that ad sales and Plus sign-ups beat expectations, it rose.

Westergren struck a ­persuasively optimistic note in a Jan. 12 ­letter to investors, writing, “We are ­realizing the advantages of having a very large, endemic audience.” In the last quarter of 2016, the letter said, Pandora picked up 375,000 Plus ­subscribers, 70 percent of them through its ­existing app -- with, that is, “minimal customer acquisition costs.” Which, he wrote, “bodes well for the launch of Premium later this quarter.”

But to enter the on-demand ­business, Pandora needed to strike deals with record labels -- and to do that, it had to agree to slightly higher royalty rates for its radio service. (Westergren, who has held a ­variety of titles in addition to his seat on the board of directors, was named CEO in March 2016 to finish negotiating those deals and lead the company to the paid-­subscription promised land.) “They basically agreed to wipe out the current profit on their ongoing business in order to get into a new one,” says Michael Pachter, an analyst at Wedbush Securities.

“Our big dilemma was, our radio product was ­profitable,” says Westergren. “To step outside of that is a massive change. And when you’re a public company, you’re making a very public bet.”

In 2016, on-demand streaming went from the fastest-­growing sector of the U.S. music ­industry to the dominant one -- and spurred real growth in the recorded-music ­business for the first time in a decade. In 2017, the streaming business will begin to solidify. By December, Spotify will likely have gone public, Apple Music may be a formidable competitor or a ­distant No. 2, and Amazon will have ­established itself as either a ­significant force or, possibly, an also-ran.

Whatever headway Pandora makes against its competitors, paid ­subscriptions generate so much more money than ad-supported listening that the company certainly stands to increase its revenue. Meanwhile, the record labels are welcoming Pandora into the fray: The paid tiers are all upside for music companies (although not necessarily artists, who get paid directly for online radio), and the company’s free operation poses less of a threat to ­subscription services than YouTube. Perhaps most important, Pandora will provide more of the competition that label and ­publishing executives hope will ­prevent one ­company from ­owning the ­subscription business the way Apple dominated downloads.

Some technology executives would say that Pandora is pivoting, moving away from a slow-growth business before getting left behind. But Westergren is committed to online radio -- and he’s not like most technology executives. After ­college he toured clubs and ­struggled to build an audience in bands. (Yellowwood Junction was the biggest -- Pandora’s algorithm compares it with the Gin Blossoms.)

In person, Westergren is ­unassuming: Before an interview over dinner at a neighborhood Italian ­restaurant in San Francisco, he asks for a quiet table in back, then ­immediately lets the matter drop when the waiter tells him the rear is closed off.

“Starting a business was never my life plan,” says Westergren. “I’m not in the mold of [Uber CEO] Travis Kalanick and those guys who are gunning from day one. I know a lot of them, but it’s not my social circle -- I’d rather stay home with my ­family.” (Westergren, who’s reluctant to reveal details about his personal life, lives with his wife and child in San Francisco.) When Pandora went ­public, his stock was worth more than $50 million -- and his big splurge was a used Steinway baby grand piano.

After Westergren had his fill of sleeping in vans on tour, he began working as a film soundtrack ­composer and got interested in how directors spoke about music. Instead of describing it as “upbeat” or “Beatles-esque,” he wondered, couldn’t they classify it by objective characteristics -- rhythm, melody, instruments used? In 1999, with the help of two friends, Will Glaser and Jon Kraft, Westergren started the company that became Pandora, hiring moonlighting musicians to rate songs on hundreds of characteristics.

Finding a business model was harder. At one point in 2003, ­running the company on maxed-out credit cards, Westergren got so panicked that he went to a hospital emergency room, thinking (wrongly) that he was having a heart attack. In 2004, Pandora launched its ad-­supported online radio service, paying labels and artists according to government-set online radio royalty rates. That system helped Pandora grow. But it didn’t give the company the ­flexibility it needed to keep up with newer rivals. By the beginning of 2016 -- when Spotify had captured about 25 million subscribers and Apple more than 10 million -- Westergren says Pandora’s growth was “kind of at a standstill.”

The day before Westergren is to make his pitch in Las Vegas, Pandora’s downtown Oakland office buzzes with the typical muted energy of a tech company, ­programmers bent over desks with their headphones on. In the conference room named Paul (which overlooks a courtyard alongside John, George and Ringo), Steve Hogan, the amiable manager of music ­operations and longtime overseer of the Music Genome, uses a wall-mounted screen to show how the company’s ­software breaks music down into a kind of math. “If you pick one song, we can calculate the distance between that song and every other song in our ­collection,” says Hogan. “We could give you a ranked list and say, ‘Starting with “Ob-La-Di, Ob-La-Da” by The Beatles, here are your top thousand closest matches.’"

One of the most striking things about Pandora Premium is what it doesn’t have: human-curated ­playlists, like those on Spotify and Apple Music. Users can select a few tracks that fit a certain mood or style, have Pandora build a station around them and either sit back and enjoy or decide which of the selected tracks to keep. The idea is that Pandora has so much data on songs and ­individual users’ reactions to them that it can pick them better than a DJ. Ahmir “Questlove” Thompson, the company’s ­“artist ambassador” and adviser, says: “You have musicians” -- Pandora’s researchers -- “putting their ­knowledge together to give you something that you might have missed.” (Questlove has said he was given equity in the company for his role there.)

The Music Genome operates in the background of Pandora Premium. When a queue ends, the app automatically plays music suggested by those songs, so users aren’t left with what Westergren mockingly calls “deafening silence.” The design of the ­service combines DNA from Pandora and Rdio, a respected but lesser-known ­subscription service that sold Pandora some of its assets after it went bankrupt. “It’s the elegance of Rdio and the ­simplicity of Pandora fused together,” says Chris Becherer, who came from Rdio and is vp product at Pandora’s listener group. Questlove particularly loves one little touch: The ­background of the mobile app changes color to complement the cover of the album that’s playing.

Pandora Plus, the $4.99-a-month ad-free radio option, allows users to skip and repeat songs and listen offline. While all three tiers share a sensibility and design ­aesthetic, the lower two don’t exist mainly to market the on-demand ­service, as Spotify’s free service does -- they’re different products that target ­different ­consumers. Pandora may have an ­easier time ­persuading users to upgrade, though, since the distinctions among them will be so substantial. “We think of it as a ­pyramid,” says Westergren, “not a funnel.”

The launch of premium not only represents a major shift in Pandora’s business model -- it required Westergren to make amends with pretty much the entire music industry. On the ­morning of March 28, 2016, shortly before Pandora announced that he would become CEO, Westergren sent three emails, one each to the chief executives of the major record companies. “I said, ‘I’m taking this job, and I want to come talk to you,’ ” he remembers. Two days later, he flew to New York to meet with Doug Morris, the CEO of Sony Music Entertainment.

“I was prepared to get my ass handed to me,” says Westergren. In 2012, Pandora began pushing the Internet Radio Fairness Act, which would have substantially lowered the royalties it paid to labels and ­musicians. At one point, Westergren sent independent ­musicians an open letter encouraging them to sign an “Artists for Internet Radio” petition that supported outlets like Pandora -- without mentioning that the company was pushing to lower rates. And in a bold 2013 work-around, Pandora bought KXMZ, a small radio station in Rapid City, S.D., then filed a motion in a rate court to pay the lower rates such stations were entitled to online.

During Pandora’s disputes with labels and publishers, lobbyists played up Westergren’s wealth: At one point he was making about $1 ­million a month selling stock. (Today, Westergren says, “There isn’t a single personal financial adviser who wouldn’t be advising anybody whose entire net worth is in one stock to sell.”) “It got so nasty and personal,” says Westergren. “We put a big target on our back, the way we approached it.”

In 2013, as Spotify gained ground, Westergren (then chief ­strategy ­officer), president/CFO Mike Herring and former chief technology ­officer Tom Conrad reversed strategy, agreeing to work with the labels and publishers rather than against them. “We decided that fighting in Washington was never going to ­create a business model,” says Herring. “The way we were going to make this a big business was to have the music ­industry on our side.”

That took years of work, ­including a serious investment in building promotional tools to help labels and artists. Pandora introduced an Artist Marketing Platform that allows acts to record brief promotional ­messages that play before their songs in certain areas at no charge; bought data ­company Next Big Sound so it could share more information with ­artists; and purchased Ticketfly, which means Pandora can now sell tickets to shows that it helps to market. “They’re focused on trying to repair their relationships in the music business,” says ASCAP CEO Elizabeth Matthews. “Especially with creators.”

?Westergren says productive ­negotiations with the labels really didn’t start until he could “look across the table and say, ‘You know what? We f—ed up.’ ” (Westergren replaced former CEO Brian McAndrews, who had a background in ­advertising but, several music industry sources say, was less adept at dealing with label executives.)

When Westergren met with Morris, he told him, “‘Mr. Morris, when I was 25 years old I was playing in rock bands, touring around in a van, and I read all about you. I never thought that one day I’d walk into your office and shake your hand.’” They talked music for about an hour. By September, Pandora had the deals it needed. “Pandora went from a pariah to a partner,” says RIAA CEO Cary Sherman.

In the music business, ­nothing salves the wounds of former ­opponents faster than an ­opportunity to make money together. And Pandora represents a big ­opportunity. “They have 80 million users,” says Sony/ATV Music Publishing ­chairman/CEO Martin Bandier, “so we all want it to work.”

The question for Pandora, of course, is how many of these users will pay up. “I’ve seen this movie before,” says Westergren. “When Pandora came on the scene we were far from the first and there were big incumbents: Yahoo, Microsoft, AOL. If you build a better product, people will come to you.”

Tim Westergren and Questlove talk about Pandora's Music Genome Project, which involves trained musicians categorizing songs to create Pandora's algorithm. Watch them discuss the process below.

This article originally appeared in the Jan. 28 issue of Billboard.