It was recently announced on the official Pokémon website that more Mega Stones are now obtainable in Pokémon Sun and Pokémon Moon via Mystery Gift. The Mega Stones available this time around are Pidgeotite, Steelixite, Heracronite and Houndoominite, which Mega Evolve Pidgeot, Steelix, Heracross and Houndoom respectively.
Like previous Mega Stone events, the Pokémon that can Mega Evolve with these newly available Mega Stones do not appear in the wild in either Pokémon Sun or Moon. Therefore, you will first have to catch (or already have) Pidgeot, Steelix, Heracross and/or Houndoom in other Pokémon games and then transfer them into Pokémon Bank using the Poké Transporter before ultimately transferring them into Pokémon Sun or Moon. Held items will not survive all this transferring, so if these Pokémon are already holding Mega Stones, they will lose them in this process.
Once you have your desired Pokémon in your Sun or Moon game, you are ready to get your Mega Stones. Select “Mystery Gift” from the game’s main menu instead of “Continue.” Then select “Receive Gift,” select “Get with Code/Password,” then press “Yes” and “Yes” again. Once you are connected to the internet, you will be prompted to enter the code. The code for this event is “AZUL.” Once you enter the code, your game will receive the four Mega Stones. Now continue your game and talk to the deliveryman in any Pokémon Center and you will get the Mega Stones. Lastly, make sure you save your game so you don’t lose your newly acquired Mega Stones.