Lets ask the general question
When does $x<y\Rightarrow y^x<x^y$ hold for real $x,y$?
Taking logarithms, we are asking when $x<y$ implies $x\log y<y\log x$, or when $$\frac{x}{\log x}<\frac{y}{\log y}.$$ Notice this is the same as when the function $f(x)=\frac{x}{\log x}$ is increasing. To answer that we look at the derivative, and since
$$f^{'}(x)=\frac{\log(x)-1}{\log^2(x)}$$
we see the derivative is only positive, and that the function is only increasing, when $x>e$. Hence if $x,y>e$ you will have $$x<y\Rightarrow y^x<x^y.$$
If $0<x,y<e$ and $x,y\neq 1$, then the derivative is actually negative, and we get the opposite $$ 1<x<y<e,\ x,y\neq 1\ \Rightarrow y^x>x^y.$$