The Scot, who was close to retiring five months ago due to the hip injury which left him struggling to walk without pain, let alone play tennis, strolled off with the silverware at his first attempt back.
Murray and Lopez - the latter 'fresh' from winning the singles title less than an hour earlier - beat Britain's Joe Salisbury and Rajeev Ram of the United States 7-6 (6) 5-7 10-5 after a third-set match tie-break.
Murray had insisted after their first-round victory that winning was not his number one priority this week. After all, it was only five months ago that the former world number one tearfully announced that the Australian Open could be his last tournament.
This, then, was supposed to be a tentative comeback, testing out the new metal hip after a career-saving operation and getting a few games under his belt, with a view to gradually building up to a return to singles. But the three-time grand slam champion clearly has not lost the appetite for a battle.
The fledgling partnership were 5-1 down in a first-set tie-break but fought back to level, and took it when Ram pushed a forehand wide.
The second set went the way of Salisbury and Ram after Murray dropped serve, and like so many matches during Murray's career, it went to the wire.
Lopez, who must have been running on empty, somehow conjured up a series of stunning winners in the match tie-break to secure his own personal double and an unlikely, but welcome, victory for Murray.
Join our new commenting forum
Join thought-provoking conversations, follow other Independent readers and see their replies