I had this same problem. I was using axis inside a tikzpicture which was inside a node from a tikzpicture (so my axis was in a 'nested' tikzpicture). The node had [anchor = north] . Removing this anchor fixed the issue.
[anchor = north]