Are there any differences between Pokémon Sun & Moon? Obviously there are changes in the Pokémon you can catch in either version as well as the legendaries, so including those are there also additional changes such as NPC changes, areas you can visit, specific mechanics?
Serebii has a summary of all of the differences between the two versions.
In Pokemon Sun the first totem pokemon you encounter is Gumshoos whilst in Moon you encounter an aloan Raticate.
In Pokemon Sun you have the ability to meet and battle Kiawe whilst in Moon you can meet and battle Mallow.
You can also get different stores in the festival plaza. You can usually get them in both games to begin with but the higher level versions of them are only available in one version.
In the Battle Tree you have the ability to scout trainers. You can only scout Plumeria, Sina and Kiawe in Sun and you can only scout Guzma, Dexio, Malloww. As far as I know other characters can be scouted in both games.
In terms of gameplay, the difference is that whilst playing Pokémon Sun, the in-game weather will be day, during real life daytime. Playing Moon during the day however will have a night weather effect.
Before you buy one, you should conisder two things: 1. When you are going to be playing the game. 2. Which lighting you prefer, light/dark.
Hope this helps.
Apart from the specific pokémon and legendaries, the main difference is the shift in time. The time of the clock would be exactly the same as the in-game time in Pokémon Sun, while it is shifted by 12 hours (i.e., AM would turn to PM and vice versa) in Pokémon Moon.
Apart from that, there are other differences such as the different Totem pokémon and ally pokémon, and a specific pokémon has a different evolution depending on the game.