Not everyone can buy Mega Millions lottery tickets online. For one thing, you must be a resident of one of the states where online lottery tickets are sold, and you must physically be located within that state's borders at the time you are buying Mega Millions tickets online.