Don't know if the question is appropriate for math-overflow, but I will try to quickly answer it anyway. The rule is not totally universal, but it has become very common. It is certainly the norm in theoretical computer science (my area). It is common enough that when the author order is not alphabetical, it looks strange. One assumes that the first authors must have done almost all the work (and the others probably insisted on being listed behind them).