The story of Ganesha circling the world confirms his status as the head of the celestial armies.
Once, Devas (gods) had to participate in a competition to choose the head of the Gana – the flocks of semi-divine beings serving Shiva. The competition required all the participants to encircle the world as fast as possible and return to the feet of Shiva. All gods at once climbed on their vehicles and set off to circle the world. Ganesha also participated in the race with the intention of winning, but his chances were meager owing to his gigantic body and less-imposing vehicle, a mouse! Ganesha was saddened at this thought, but he decided to try his luck.
Just a short while after, Narada, the son of Brahma, appeared before him. Ganesha got displeased at this encounter with a solitary Brahmin, as it is not a good omen in any endeavor. Narada enquired about his trip, making Ganesha more furious, as asking somebody about his destination in the middle of his journey is considered unlucky. Narada calmed down Ganesha with great efforts and understood the reason for his anguish.
Clever Narada suggested a wise idea to Ganesha to win the game. He encouraged Ganesha to go back to his father and circle around him, as Shiva personifies the whole world. Ganesha agreed and returned to his father. Surprised Shiva asked him whether he could finish getting around the world so fast. Ganesha explained Narada’s guidance, and Shiva was pleased with the advice. Shiva declared Ganesha as the champion of the race and conferred him the name Ganapati – meaning the leader (pati) of celestial armies or Ganas. He was also acclaimed with the name Vinayaka (lord of all beings).