Both are of a Progressive mind set. Right and left.
By modern Western political systems, they are both left. The left/right paradigm of communists/nazis originated at a time when it was being compared to the monastic empires. That dicotomy doesn’t really fit in today’s world.
Both were leftist-collectivists. They just worked differently. Communists centralized control from the bottom-up, Nazis from the top-down.