Later this month, Sam Smith will unveil "Writing's on the Wall," the theme song for the upcoming James Bond movie Spectre. If it succeeds, it will propel Smith's fame to staggering new heights, introduce him to millions of new listeners, and put him in prime contention for a murderer's row of trophies, including Grammys and an Oscar. If it fails, it will earn Smith an unhappy place in infamy, on its way to an endlessly extended shelf life of being picked apart and mocked by generations of 007 fans.

No pressure, though.

A truly great James Bond theme lies at a cross-section of paradoxes. The franchise's best songs are simultaneously timeless and representative of the eras in which they were recorded. They capture the specifics of each movie while embodying, in a larger sense, the franchise's rich history. And while the songs feel inseparable from the context of the movies that inspired them, they're also strong enough to stand on their own.

So how does an artist begin to climb that creative mountain? If you're looking for inspiration, you can't start at the beginning. Dr. No, the first James Bond movie, plays its opening credits as a montage, beginning with the now-iconic "James Bond Theme" composed by Monty Norman and ending on the "Kingston Calypso," as performed by Byron Lee and the Dragonaires.

The tradition of James Bond themes didn't really begin until the second movie, From Russia with Love. Even then, the lyrical version sung by Matt Monro, which most people consider the movie's theme song, was relegated to the closing credits. Instead, the opening is set to an instrumental rendition of "From Russia with Love" that gradually gives way to the "James Bond Theme."

The James Bond theme as we know it didn't arrive until 1964's Goldfinger — and when it comes to 007, "Goldfinger" is still the platonic ideal. From the opening blast of the orchestra, it's bold and brassy and unforgettable — but where a lesser singer might be drowned out, Shirley Bassey manages to loom over the instrumentation. Best of all, the song is an ideal match for the film that spawned it, capturing Goldfinger's tone and priming the audience (as well as providing the framework for composer John Barry's overall score). Unlike the previous two 007 movies, there's no need to cut to the "James Bond Theme" at the end, because "Goldfinger" smuggles that song's key refrain into its closing lines — but even if it didn't, the song is basically the pure distillation of Goldfinger in musical form.

But is "Goldfinger," for all it brilliance, the best musical template for the James Bond series as a whole? The producers certainly feel that way; there's a reason Shirley Bassey is the only singer who has ever been tapped to perform more than one Bond song. But attempts to replicate the "Goldfinger" formula have never quite measured up.

"Mr. Kiss Kiss Bang Bang" — which was originally intended as the theme for the Goldfinger follow-up Thunderball — shares Goldfinger's sharp, lush orchestration, and was even originally sung by Shirley Bassey. It's not nearly as good:

"Mr. Kiss Kiss Bang Bang" was eventually dropped in favor of "Thunderball," the follow-up song performed by Tom Jones, which could hardly have hewed more closely to the "Goldfinger" formula. It borrows the title of the movie; its lyrics focus on the villain, not Bond; and the orchestration is even more brassy and bombastic than "Goldfinger." Bassey once said she held the final note in "Goldfinger" so long that she felt faint; Jones, in turn, has claimed he held the final note of "Thunderball" for so long that he passed out.

So why doesn't "Thunderball" measure up? It's a subjective question, but you won't find many people arguing that "Thunderball" is equal to "Goldfinger." Then and now, "Thunderball" sounds like a shallow imitation of "Goldfinger" because that's pretty much what it is. A decade later, "The Man with the Golden Gun" — a similarly transparent attempt to do another "Goldfinger," as performed by Scottish pop singer Lulu — fared even worse.

So if "Goldfinger" wasn't the key to a great Bond theme, what was? The 007 franchise scored its first international chart-topper in 1973 with a song that represented a major musical detour for the franchise: Paul McCartney & Wings' "Live and Let Die," which kicked off Roger Moore's big-screen debut as 007.

The sheer impact of combining two of England's most beloved pop-cultural exports was always going to make a splash, but "Live and Let Die" transcended novelty to become what's widely acknowledged as another of the all-time great Bond songs. Beginning with a steady, teasing piano intro that crescendoes into a rousing instrumental section, "Live and Let Die" suddenly zigzags again, with a goofy, cheery bridge, complete with slide whistle. The song is as rapidly paced and unpredictable as any of James Bond's missions, but it's also unusually well-suited to its era; with its constant shifts in both pace and tone, "Live and Let Die" is the musical encapsulation of a Roger Moore 007 movie.

The next great Bond song came just a few years later, shaking up the formula once again. Following the tepidly received "The Man with the Golden Gun," Carly Simon tossed out a new curveball for The Spy Who Loved Me: "Nobody Does It Better," a lovely smash-hit that offers a surprisingly apt encapsulation of the breezy Bond film that inspired it (while vaguely recalling Nancy Sinatra's underrated "You Only Live Twice").

Despite the apparent specificity of a lyric like "the spy who loved me is keeping all my secrets safe tonight," the song became a crossover mainstream hit. But like "Goldfinger," subsequent attempts to replicate the success of "Nobody Does It Better" — including Sheena Easton's "For Your Eyes Only" and Rita Coolidge's "All Time High," from 1983's Octopussy — have paled in comparison.

To my mind, "Goldfinger," "Live and Let Die," and "Nobody Does It Better" collectively embody the two greatest lessons for any artist recording a 007 theme: Tailor your song to the strengths of your Bond, and don't try to replicate the songs that came before yours.

But even those relatively reliable pieces of advice sometimes fall flat. Some Bond songs — a-ha's "The Living Daylights," Madonna's "Die Another Day," Jack White and Alicia Keys' "Another Way to Die" — are very representative of the movies for which they were created. Unfortunately, those movies aren't very good. There's a final wrinkle to the formula that's totally out of an artist's hands: If you want to write a great 007 theme, make sure it's going to be in a great 007 movie.

And that brings us to the most recent entry in the James Bond musical canon: Adele's "Skyfall," the first 007 theme to win an Oscar. But as well-deserved as that trophy was, the song didn't need the Academy to legitimize it; "Skyfall" was, pretty much instantly, acknowledged as one of the all-time great songs in the 007 canon.

And like the great 007 songs before it, "Skyfall" hits every paradoxical bullet point on the list. Skyfall — which reintroduced modernized versions of Moneypenny, Q, and even a male M — had one foot in the past and one foot in the future, and the song follows suit. "Skyfall" feels both specific to the film that inspired it, and consistent with the long history of the franchise. It relies on one of today's most successful and acclaimed recording artists to deliver something that's both modern and timeless. There's a reason Daniel Craig cried the first time he heard it.

So yeah, it's not an easy job. But there's a final silver lining for any artist tapped to perform a Bond theme: great or terrible, your song and your name will forever be linked with one of the biggest and most enduring franchises in Hollywood history. That's the kind of immortality that only 007 can offer.