The Sherlock star appears as The Captain in the upcoming Christmas special after his friend and co-writer Steven Moffat created a part for him in his last episode.
Speaking on Friday’s Lorraine, he said: “It was a very touching thing. I created Sherlock with Steven. We’ve been friends for years. I’ve written for Doctor Who since it came back.
“Earlier this year Steven said to me, ‘Will you keep the summer free because I’ve written a part for you in Peter’s last story and I want you to be there when I go.’”
The 51-year-old actor confessed: “We were all in tears. It was the screening the other night and we were all in tears I’m afraid. It’s happy and sad.”
Twelfth Doctor Peter Capaldi will be replaced by Jodie Whittaker, the first female to hold the role in the show’s history ¬¬– a move hailed by Mark as a “new era”.
He said: “It’s fantastic. What I love about this, I love the costume – I call it ‘Godspell chic’. It’s got a lovely early 70s feel to it, which I really like. I think it’s a fantastic choice, Jodie, it’s a whole new era. And I don’t know anything about it which is a position I’ve not been in since 2004.”
Gatiss also admitted that Sherlock might not be over for good after being off screen since January 2017.
He explained: “We deliberately left it in a sort of happy place where we could go back. We have no plans at the moment. Steven and I are going to do Dracula.”