That track came from the studio of Max Martin, the Swedish producer whose influence on 2000s pop is matchless — his guiding hand firmly behind the careers of Britney Spears, Kelly Clarkson and Katy Perry. He works with a large team of writers and producers out of a sprawling residential compound in West Hollywood that was once home to Frank Sinatra. Martin’s hit-factory typically solicits little creative input from the talent, who show up when it’s time to sing. This process was alien to Tesfaye, who had always written his own lyrics and was unsure that he would be a good match for Grande’s good-girl gleam. When he saw the lyrics that were sent to him, he found them to be tepid. He rewrote his verse, recorded it and sent it back.
What could have been a contentious exchange was actually edifying for both parties: Martin liked Tesfaye’s changes and kept them; Tesfaye realized he could make sleek, accessible pop on his own terms. He asked Goldstein to secure Martin’s services for his next album. ‘‘If I’m gonna be the biggest in the world,’’ he told her, ‘‘I need a handful of songs like that.’’