This is obviously a subjective question, but I teach this in two phases
(1) I need to know this fact very early, so I give the quickest definition I know: $$\mathtt{sign}(\sigma) = \frac{\prod_{i<j} \left( x_{\sigma(i)} - x_{\sigma(j)} \right)}{\prod_{i<j} \left( x_i - x_j \right)}.$$ This makes it clear that $\texttt{sign}$ is well defined and is a group homomorphism, but does look rather like pulling a rabbit out of a hat. On the positive side, it is early practice in computing group actions on polynomials, which the students need any way.
But then, for motivation, a week or two later:
(2) I have students classify all group homomorphisms $\chi: S_n \to A$ where $A$ is abelian. Since $S_n$ is generated by transpositions, $\chi$ is determined by its value on transpositions; since every transposition squares to $1$, we must have $\chi((i\ j)) = \pm 1$; sincetranspositions. Since any two transpositions are conjugate, wethere must either havebe one value $\chi((i \ j))=1$$z$ which is $\chi((ij))$ for all $i$, $j$ or $\chi((i \ j))=-1$ for all, since $i$$(ij)^2=1$, we must have $j$$z^2=1$. So either we have the trivial character, or else we can call $z$ by the name $-1$ and we have the sign character.
This explains why $\mathtt{sign}$ is inevitable — it is the only nontrivial character of $S_n$, so anyone mucking around with $S_n$ has to discover it.
As a bonus, the computation in part (2) can exactly be mimicked to show that $A_n$ has no nontrivial characters for $n \geq 5$: $A_n$ is generated by $3$-cycles, any character must take the $3$-cycles to cube roots of unity, but (for $n \geq 5$) every $3$-cycle is conjugate to its inverse, so in fact every character is trivial on the $3$-cycles.