Auckland Mayor Len Brown was left red-faced after he accidentally texted John Key, thinking the Prime Minister was his wife.
Mr Brown said he had learned his lesson and "it shows the importance of checking whether you're texting your Prime Minister or your wife".
The pair exchanged a light-hearted conversation at the opening of Wynyard Quarter last Saturday about who would win that night's All Blacks game against Australia.
Mayor Brown picked the All Blacks to win by 15 points, but Mr Key was not as confident and said the match would be closer.
The All Blacks beat Australia 30-14 - a margin of 16 points.