linguistic:paraphrasing, quality:correction
Founding

Prior to the Maurya Empire, the Nanda Empire ruled over a broad swathe of the Indian subcontinent. The Nanda Empire was a large, militaristic, and economically powerful empire due to conquering the mahajanapadas. According to several legends, Chanakya travelled to Pataliputra, Magadha, the capital of the Nanda Empire where Chanakya worked for the Nandas as a minister. However, Chanakya was insulted by the Emperor Dhana Nanda when he informed them of Alexander's invasion. Chanakya swore revenge and vowed to destroy the Nanda Empire. He had to flee in order to save his life and went to Taxila, a notable center of learning, to work as a teacher. On one of his travels, Chanakya witnessed some young men playing a rural game practicing a pitched battle. One of the boys was none other than Chandragupta. Chanakya was impressed by the young Chandragupta and saw imperial qualities in him as someone fit to rule.

Meanwhile, Alexander the Great was leading his Indian campaigns and ventured into Punjab. His army mutinied at the Beas River and refused to advance farther eastward when confronted by another army. Alexander returned to Babylon and re-deployed most of his troops west of the Indus River. Soon after Alexander died in Babylon in 323 BCE, his empire fragmented into independent kingdoms led by his generals.

The Maurya Empire was established in the Magadha region under the leadership of Chandragupta Maurya and his mentor Chanakya. Chandragupta was taken to Taxila by Chanakya and was tutored about statecraft and governing. Requiring an army Chandragupta recruited and annexed local military republics such as the Yaudheyas that had resisted Alexander's Empire. The Mauryan army quickly rose to become the prominent regional power in the North West of the Indian subcontinent. The Mauryan army then conquered the satraps established by the Macedonians. Ancient Greek historians Nearchus, Onesictrius, and Aristobolus have provided lot of information about the Mauryan empire. The Greek generals Eudemus and Peithon ruled in the Indus Valley until around 317 BCE, when Chandragupta Maurya (with the help of Chanakya, who was now his advisor) fought and drove out the Greek governors, and subsequently brought the Indus Valley under the control of his new seat of power in Magadha.

Chandragupta Maurya's ancestry is shrouded in mystery and controversy. On one hand, a number of ancient Indian accounts, such as the drama Mudrarakshasa (Signet ring of Rakshasa – Rakshasa was the prime minister of Magadha) by Vishakhadatta, describe his imperial ancestry and even link him with the Nanda family. A kshatriya clan known as the Mauryas are referred to in the earliest Buddhist texts, Mahāparinibbāna Sutta. However, any conclusions are hard to make without further historical evidence. Chandragupta first emerges in Greek accounts as "Sandrokottos". As a young man he is said to have met Alexander. Chanakya is said to have met the Nanda emperor, angered him, and made a narrow escape.