Costume crime drama Ripper Street has been resurrected and is heading back to the BBC as part of a deal with internet giant Amazon that will see it premiere online before being shown on TV.
The new series of the show, axed last year after the BBC said it " didn't bring the audience we hoped", will be shown first on Amazon's on-demand Prime Instant service which will also re-run the first two series.
Cast members including Matthew Macfadyen and Jerome Flynn, who both play detectives working in 19th-century Whitechapel in east London, start filming in May.
Speaking at a press conference in London to announce the new deal, stars of the show Matthew, Jerome and MyAnna Buring expressed their delight.
Matthew, who stars as Detective Inspector Edmund Reid, said: "I was surprised by the decision to cancel it, I think, and slightly dismayed.
"I was just surprised because I think we all felt it had legs, we didn't feel it was petering out. And then I was delighted by the news."
MyAnna, who plays Long Susan, said: "I feel delighted and very grateful to Amazon for bringing it back."
She also thanked fans for their online campaign to save the show, adding: "The response was very moving so thank you to the audience."
Jerome, who plays Detective Sergeant Bennet Drake, said: "I was shocked as well. It was strange though, because I couldn't believe it was the end. It felt energetically like it was unfinished work.
"We've become a really close family the Ripper Street lot and it really felt like we had more to do. So I couldn't take it in and then Amazon came along and it feels right."
The third series will be a co-production with the BBC, which will contribute funding.
Producer Simon Vaughn, chief executive of Lookout Point, said: "The BBC are contributing to the production costs; in fact, we had to get a lot of people to contribute to the production costs. Amazon are the White Knight who came to the rescue.
"However, everybody still loves the show. We've got broadcasters around the world, BBC America, who are broadcasting the show very happily, BBC, who all love the show. So it was an easy sell and about getting five or six people back to the table and everybody seeing there was a new way to keep the show on the road."
Writer Richard Warlow said he had always planned more series of the show and said the new partnership with Amazon would allow a way of adding more "bells and whistles" to the production which were not possible when it was being made just for BBC One.
He said: "It's really exciting from a creative point of view, if you're writing exclusively for a terrestrial broadcaster there are all sorts of parameters that you have to consider all the time. Whereas the opportunities that Amazon are giving us are to make the show that I always imagined from the very beginning, with slightly more bells and whistles actually."
Warlow revealed: "Series three will start in 1894, and we're going to have a look at the railways in the first episode. And there is something else which happened in 1894, the Macnaghten Memorandum. Melville Macnaghten was the assistant chief commissioner of the London Metropolitan Police who wrote an internal report that was for police eyes only, in which he named three suspects who he believed could have been Jack the Ripper."
Jason Ropell, head of Amazon instant video international content acquisition, said: "We're delighted to have secured not only the highly popular first two seasons of Ripper Street for our Prime Instant Video customers, but we can also confirm today that we will making season three, news that we know will delight the millions of fans of this brilliant British drama."
BBC drama boss Ben Stephenson said this was "an exceptional opportunity" to bring the show back.
He said: "This deal gives fans another series of the show they love at excellent value to the licence fee-payer, ensuring that the BBC can also commission an entirely new, yet-to-be-announced drama series."