In an eventful renewal, Ahoy Senor set a searching gallop until getting too close to the sixth fence from home and crumpling on landing.
Townend had bided his time, tracking the early pace before getting into contention coming down the hill, tailing Protektorat, Bravemansgame and Hewick, who had been left in front.
He crashed through the third-last, which almost cost him the race, but quickly recovered and by the time American Grand National hero Hewick had come to grief two out, Irish Gold Cup winner Galopin Des Champs had gone upsides Harry Cobden and the Paul Nicholls-trained Bravemansgame.
Both jumped the last on a good stride, but the King George winner could not find the same turn of foot as Townend drew clear.
Galopin Des Champs (7-5 favourite) had seven lengths to spare at the line, with Conflated a further sixth and a half lengths down in third.
Mullins said: “I didn’t realise the pressure I was under. I’m absolutely delighted for Audrey Turley (owner), Paul was under huge pressure too and gave him a peach of a ride.
“The plan was to drop him in and come through, I said to him ‘I think you’re on the best horse, the fastest horse, so as long as he doesn’t get running with you just tuck him in somewhere and put him asleep’ – and he did.
“It just worked out, he gave him a brilliant, cool ride. Everyone was questioning the distance and his stamina, they were going to make it plenty fast so I didn’t want him up there in the early exchanges.
“If he has the class, he’ll come through, if he hasn’t then there’s no point.
“All the thoughts go through your head, have we gone too far back? They had gone such a gallop, something had to give.
“One or two fell and we missed all that, we’d a lot of luck. I think that man on board, when the pressure comes on, he’s very good.”
He added: “I was surprised myself how I was over the last two fences. With this horse, we’d elected him as our Gold Cup horse whereas Al Boum Photo sort of just happened. This fellow, we thought he was good enough and that puts you under pressure.
“Every time we’ve upped him in trip, it’s been no problem. He has that bit of class, you could run him over two miles, two and a half miles. He has that bit of speed when you want it.”
Townend – like Mullins winning this third Gold Cup – said: “It was messy for me – I couldn’t get a clean passage early, and he started jumping in the air a little bit, but when I got a bit of room, in fairness to him he came back into a rhythm with me and was very, very brave.
“I think he got me out of a fair hole, to be honest – I was a lot further back than I wanted to be, but it was just the ride I had to give him.
“There was so little fresh ground that everyone wanted to be in it, and the start was very messy.
“He was good and brave. There were horses going left of me and right of me (when the two horses fell at the top of the hill) and he always just found a leg, and you need that luck in racing.
“He missed one of the fences coming down the hill, and I thought that was going to put me on the back foot a bit again, but no, straight back on the bridle for me. I don’t think the horse understands how good he is, to be honest.”
He went on: “The Gold Cup brings winning to a different level. Cheltenham is very important, but the Gold Cup just has that little bit more spice to it.”