George North scored two tries for the Six Nations champions, with Leigh Halfpenny, Dan Biggar and Rhys Priestland all contributing from the kicking tee, but a 30-16 deficit in the second half was too big to overcome.
And despite tasting defeat to Australia once again, Gatland took solace in the fact his side were able to put themselves in a position to win the game and made a real contest of things.
"It was a great game of rugby if you were a neutral or an Australian. It was a real Test match out there," Gatland said.
"We are knocking on the door. The thing is with the southern hemisphere now, which is different to the past, is that they are coming here fully loaded and not making changes.
"We dug deep, and we showed courage to come back. Our fitness looked good in the second half, and we put ourselves in a position where we had a chance to win it.
"It was frustrating that of the 18 penalties we got, I think 14 were at the breakdown, which stopped some of the momentum we were trying to create.
"We will review a few things in the game, whether we would have made different decisions that might have affected the outcome, but I just thought the last period of the game we looked pretty good.
"As a whole, we are disappointed we didn't win."