"The Valley of the End" (終末の谷, Shūmatsu no Tani) is episode 475 of the Naruto: Shippūden anime.
The Kage's spirits depart. Now free, the tailed beasts make plans on where to go. Hagoromo asks Kurama to return to Naruto, who due to having a bit of each of their chakra, can act as a gathering place for the tailed beasts to communicate. Hagoromo asks Naruto and Sasuke if the answers they gave him before have changed. Naruto says his hasn't changed, and having fought Kaguya, that he is glad Kushina was his mother. Hagoromo explains that Naruto and Sasuke, having the tailed beasts' chakra and the Rinnegan, can release the Infinite Tsukuyomi. Sasuke wants to kill the Five Kage before releasing the Infinite Tsukuyomi, to everyone's surprise, and puts the tailed beasts under genjutsu, also planning to kill them later. Naruto apologises to Hagoromo. Kakashi questions Sasuke's motives. Sasuke explains that while vengeance and destruction were his initial goals, now he wants to destroy the shinobi world as it is to rebuild it anew, blaming the Five Kage for how the world has become. Sasuke traps the tailed beasts with Chibaku Tensei. Hagoromo laments that even when bequeathing his power to both sides, the results remained the same. Sasuke is intent on killing Naruto, planning to use the captured tailed beasts to release the Infinite Tsukuyomi later. When Naruto opposes him, Sasuke tells Naruto they need to fight somewhere else. Sakura tries appealing to Sasuke by telling him that she still loves him but he puts her under genjutsu to keep her from interfering with his battle with Naruto. Kakashi scolds Sasuke for this because Sakura's love for him is making her suffer and Sasuke thinks back to his family before leaving. Naruto assures Kakashi he'll keep his promise of bringing Sasuke back. Hagoromo tells Kakashi about his sons and he believes Naruto can still save Sasuke. Naruto and Sasuke reach the Valley of the End. Naruto tells Sasuke he won't let him do as pleases, and passes on Itachi's words of what being Hokage means. Based on how Itachi lived his life, Sasuke has come up with his own interpretation of what being Hokage means.
Throughout the episode, Gyūki is depicted with the horns and tooth it lost during its battle with the Ten-Tails.
In one scene, the pattern of Sasuke's Rinnegan does not cover his entire eyeball.