The Spectre track soared straight into the top spot with 70,000 combined sales and streams, finishing 13,000 ahead of closest competitor, Justin Bieber’s What Do You Mean?
Smith told Official Charts: “It was such an honour to be asked to write and record Writing’s On The Wall and it’s incredible that it’s become the first Number one Bond theme song.
“It’s been an unforgettable experience working with Barbara (Broccoli) and Sam (Mendes) to become part of this British legacy.
“I couldn’t have done this without my fans - this is a special moment I’ll never forget.”
Writing’s On The Wall is Smith’s fifth number one single.
It is also the first James Bond theme song recorded by a British male solo artist since 1965.
Only two other 007 signature tracks have got close to the number one spot: Adele’s Skyfall and Duran Duran’s A View To Kill both peaked in second place.
Smith will unveil the full music video at an apt 00:07 on Monday October 5, to coincide with Global James Bond Day.
The rest of the top five sees R City and Adam Levine stay at three with Locked Away, Sigala’s former Number one Easy Love slip from two to four, and The Weeknd’s Can’t Feel My Face hold firm at five.
In the album charts, siblings Howard and Guy Lawrence, best known as Disclosure, bagged their second number one after the success of their 2013 debut Settle.
They said: “Can’t believe it! So happy and thanks so much to all the people for supporting our music. It means the world and we can’t wait to hopefully see you all at a show soon!”
The album, Caracal, features collaborations with Sam Smith, The Weeknd, Lorde and Miguel, among others.
New Order’s 10th album, Music Complete, was a new entry in second place and marked the band’s 10th top 10.
Last week’s number one, David Gilmour’s Rattle That Lock, slid to third place, Scottish synth band Chvrches entered at four with Every Open Eye and Jess Glynne dropped to fifth.