Liu Bang captures Wu Pass; Huhai rebukes Zhao Gao, prompting Zhao Gao to feign illness and conduct the deer-horse loyalty test.
Qin Dynasty (秦朝) · HISTORICAL EVENT
Coup of Wangyi Palace (望夷宫之变)
望夷宫之变
The Coup of Wangyi Palace (望夷宫之变) was a cataclysmic palace coup and regicide that took place in the ninth month of 207 BCE during the final days of the Qin Dynasty. As vast anti-Qin uprisings engulfed eastern China, Qin commander Zhang Han surrendered his grand army to Xiang Yu, while Liu Bang led rebel forces rapidly toward the strategic Wu Pass. Facing total military breakdown, Chancellor Zhao Gao, who had long dominated the court, purged loyal…

OVERVIEW
The Coup of Wangyi Palace (望夷宫之变) was a cataclysmic palace coup and regicide that took place in the ninth month of 207 BCE during the final days of the Qin Dynasty. As vast anti-Qin uprisings engulfed eastern China, Qin commander Zhang Han surrendered his grand army to Xiang Yu, while Liu Bang led rebel forces rapidly toward the strategic Wu Pass. Facing total military breakdown, Chancellor Zhao Gao, who had long dominated the court, purged loyal ministers, and kept the Second Emperor Huhai in complete ignorance of front-line disasters, grew terrified of imperial retribution. To secure his own survival, Zhao Gao orchestrated an armed conspiracy with his younger brother Zhao Cheng and son-in-law Yan Le. Yan Le led over a thousand armed troops into Wangyi Palace on the outskirts of Xianyang, executing palace guards and confronting Huhai inside his inner bedchamber. Rejecting all pleas from Huhai to be demoted to a feudal lord or even spared as a common civilian, Yan Le compelled the twenty-four-year-old emperor to commit suicide with his sword. Although Zhao Gao attempted to seize the imperial throne for himself, unanimous silent resistance from civil and military officials forced him to abandon his imperial ambition and install Ziying as King of Qin instead. Recognizing Zhao Gao as a treacherous menace, Ziying feigned illness, lured Zhao Gao into his fasting chamber, and directed his eunuch Han Tan to execute him. The Coup of Wangyi Palace fatally crippled Qin imperial authority, and within weeks, Ziying surrendered Xianyang to Liu Bang, marking the complete extinction of the Qin Dynasty.
EVENT TIMELINE
Zhao Gao conspires with Zhao Cheng and Yan Le to execute a palace coup, kidnapping Yan Le's mother as collateral.
Yan Le leads a thousand troops into Wangyi Palace, executes the gatekeeper, and besieges Huhai's bedchamber.
Yan Le rejects all petitions for royal or common status, compelling Huhai to commit suicide with his sword.
Zhao Gao attempts to take the imperial seat but faces total silent rejection from courtiers, forcing him to name Ziying as King of Qin.
Ziying lures Zhao Gao to the Fasting Palace, where eunuch Han Tan assassinates Zhao Gao, leading to the extermination of his entire clan.
Relationship graph
FULL ACCOUNT
Background
Military Collapse and Chancellor Deception
Following his accession to the throne, the Second Emperor Huhai relied heavily on the corrupt eunuch chancellor Zhao Gao, executing illustrious generals such as Meng Tian, prominent statesmen, and numerous imperial princes and princesses. Implementing draconian penal codes and crushing labor levies, the court provoked massive civil unrest. When Chen Sheng and Wu Guang ignited rebellions across China, scions of the former Warring States quickly rose to re-establish their ancestral kingdoms. Despite this nationwide conflagration, Zhao Gao systematically deceived Huhai, claiming that scattered bandits posed no threat and severing real military communications between front-line armies and the court.
In the winter of 207 BCE, Zhao Gao framed and executed Grand Chancellor Li Si, consolidating absolute control over the imperial bureaucracy. However, the military situation collapsed rapidly. At the Battle of Julu, Qin general Wang Li was captured by Xiang Yu, while Zhang Han suffered repeated defeats. When Zhang Han sent emissary Sima Xin to seek imperial reinforcements, Zhao Gao refused audience and harbored intentions of purging the generals. Fearing imminent execution regardless of battlefield success, Zhang Han surrendered over two hundred thousand soldiers to Xiang Yu, leaving Qin central territory almost entirely undefended.
Internal Purges and Pointing to a Deer as a Horse
With the eastern defenses obliterated, Liu Bang led the southern insurgent army into the mountainous passes, capturing Wu Pass in the eighth month of 207 BCE. Shocked by sudden enemy advances close to the capital, Huhai summoned Zhao Gao to demand explanations for the catastrophic military disasters. Terrified that his prolonged deception was exposed, Zhao Gao feigned illness and avoided attending court.
To test the loyalty and fear of court officials before staging an insurrection, Zhao Gao presented a deer to Huhai and publicly insisted it was a horse. When Huhai chuckled and consulted his ministers, courtiers terrified of Zhao Gao echoed his false assertion, while those who honestly stated it was a deer were subsequently framed and executed. Having thoroughly cowed the court into terrified subservience, Zhao Gao recognized that Huhai harbored deep suspicions against him, prompting him to organize an armed coup d'état to eliminate the emperor before imperial justice could be served.
Course of the Event
Conspiracy and Hostage Taking
In the ninth month of 207 BCE, as Liu Bang advanced toward Xianyang, secret emissaries were dispatched to contact Zhao Gao. Zhao Gao, seeking to evade execution and aspiring to divide the Guanzhong region as an independent ruler under pacts with rebels, devised a coup with his brother Zhao Cheng, Prefect of the Palace Guards, and his son-in-law Yan Le, Magistrate of Xianyang. They resolved that Zhao Cheng would act as an internal informant inside the palace, falsely raising alarms about rebel intruders, while Yan Le would lead municipal troops under the pretext of emergency defense to seize Wangyi Palace.
To prevent Yan Le from wavering or betraying the plot at the critical juncture, the ruthless Zhao Gao dispatched guards to kidnap Yan Le's mother, holding her hostage in his private residence. Under direct extortion and terror, Yan Le complied with the operational plans, assembling armored soldiers and siege weapons to launch a surprise strike against the emperor residing north of the Wei River.
Storming Wangyi Palace and Forcing Huhai's Suicide
On the designated day, Yan Le marched more than one thousand troops directly to the gates of Wangyi Palace. The officer commanding the imperial gateway challenged the unusual military presence, asking why municipal troops were mobilizing at an imperial residence. Yan Le ordered his men to bind the officer and furiously accused him of letting thieves and rebels enter the complex. When the gate officer protested that elite sentries patrolled every sector and no bandit could enter, Yan Le executed him on the spot with a sword.
Yan Le and his force surged through the palace gates. Palace eunuchs and sentries panicked and scattered in all directions, while a handful of resistant guards were swiftly overwhelmed and killed. Zhao Cheng emerged from the inner courtyard to guide the attackers directly into the private royal quarters. Archers unleashed volleys of arrows, piercing the bedchamber drapes of Huhai. Terrified, Huhai called out for his bodyguards, but all attendants had abandoned him except for a single loyal eunuch.
Retreating into his inner chamber, Huhai bitterly asked the eunuch why he had never informed him of the catastrophic reality and Zhao Gao's treason. The eunuch replied that he had remained silent precisely to preserve his life, noting that anyone who had dared speak the truth had already been executed. Moments later, Yan Le burst into the room brandishing a sword, denouncing Huhai as an arrogant and cruel tyrant whose misrule had turned all under heaven against him, ordering him to end his own life.
Faced with certain death, Huhai desperately begged to speak directly with Chancellor Zhao Gao, but Yan Le coldly refused. Huhai then pleaded to step down and receive merely the title of king over a single commandery, which Yan Le denied. Huhai further begged to be reduced to a marquis of ten thousand households, but was refused again. Finally, weeping profusely, Huhai asked only to be spared and live as a common peasant alongside his wife and children. Yan Le retorted that he carried the chancellor's explicit mandate on behalf of the realm to execute a tyrant and would hear no more words. As Yan Le advanced with drawn blade, Huhai realized doom was inescapable and ended his life with his sword at age twenty-four.
Failed Usurpation and Ziying's Installation
Following the regicide, Yan Le hurried to inform Zhao Gao. Elated by the report, Zhao Gao rushed to Wangyi Palace, stripped the imperial jade seal from Huhai's corpse, fastened it to his own belt, and climbed the elevated dais in the grand audience hall. Boasting ancient descent from the ruling house, Zhao Gao prepared to declare himself the new emperor.
However, when Zhao Gao mounted the throne, civil and military officials standing below bowed their heads in grim, unyielding silence. Not a single statesman moved forward to congratulate him or acknowledge his sovereignty. Confounded by this universal silent repudiation, Zhao Gao realized that heaven and humanity rejected his usurpation, and that forcing the issue would spark immediate armed insurrection in Xianyang. Reluctantly, he retreated from the dais and abandoned his immediate imperial ambitions.
Seeking a pliant royal figurehead to stabilize the volatile capital, Zhao Gao resolved to enthrone Ziying, a respected member of the Qin imperial house. Since former feudal states across eastern China had restored their kingdoms and Qin dominion was restricted to Guanzhong, Zhao Gao announced the abolishment of the grand title of emperor, reducing Ziying's title to King of Qin. Zhao Gao instructed Ziying to observe five days of ceremonial fasting before receiving the royal seal at the ancestral temple.
Ambush in the Fasting Palace and Zhao Gao's Execution
Ziying had long observed Zhao Gao's ruthless purges and the treacherous slaughter of the Second Emperor. Fully aware that he was intended merely as a temporary puppet while Zhao Gao negotiated with rebel armies to carve up Guanzhong, Ziying knew that proceeding to the temple ceremony would leave him vulnerable to assassination. Determined to strike first, Ziying formed an alliance with his two sons and his trusted eunuch Han Tan.
When the five-day fasting period elapsed, Zhao Gao sent repeated messengers urging Ziying to depart for the ancestral temple, but Ziying feigned grave illness and remained inside his fasting quarters. Anxious and impatient, Zhao Gao decided to visit the palace personally to persuade the prince. As soon as Zhao Gao entered the inner chamber, Han Tan drew his blade and struck Zhao Gao dead on the spot. Ziying immediately summoned court officials and imperial guards, publicly proclaimed Zhao Gao's monumental crimes, and ordered the extermination of his clan to the third degree, displaying Zhao Gao's head in the Xianyang marketplace.
Key Figures
Zhao Gao Faction
- Zhao Gao: Grand Chancellor of Qin whose tyrannical rule and deliberate suppression of military disaster led him to orchestrate the regicide of Huhai, ultimately assassinated by Ziying in the Fasting Palace.
- Yan Le: Magistrate of Xianyang and son-in-law of Zhao Gao, who personally commanded the troops storming Wangyi Palace and compelled Huhai to commit suicide.
- Zhao Cheng: Younger brother of Zhao Gao and Prefect of the Palace Guards, who acted as internal traitor to open the palace gates and order archery volleys into the bedchamber.
Qin Imperial Court and Retaliators
- Huhai (Second Emperor of Qin): Second sovereign of the Qin Dynasty, whose devotion to luxury and brutal elimination of loyal ministers ended in humiliation and forced suicide at age twenty-four.
- Ziying: Grandson of Qin Shi Huang installed as King of Qin, who brilliantly conspired with Han Tan to assassinate Zhao Gao and annihilate the chancellor's treacherous clan.
- Han Tan: Dedicated imperial eunuch who executed the fatal ambush on Zhao Gao within the Fasting Palace.
Results and Significance
Direct Results
The Coup of Wangyi Palace concluded with the forced suicide of Huhai and the extinction of the central imperial line established by Qin Shi Huang. Zhao Gao's subsequent ambition to usurp the imperial throne was thwarted by the resolute passive resistance of the civil and military elite. Although Ziying successfully purged Zhao Gao and annihilated his familial clique, the central command structure, military resources, and administrative coherence of the Qin court were irreparably destroyed.
Historical Significance
The event dealt a catastrophic and irreversible blow to the Qin imperial enterprise. The violent overthrow and regicide of the sovereign inside his personal palace shattered the aura of imperial sanctity, entirely dispelling the willingness of Guanzhong subjects and garrison troops to defend the regime. Less than a month after the coup, Liu Bang's forces arrived unopposed outside the walls of Xianyang. Ziying emerged with a plain carriage and white horses, surrendering the imperial jade seal, thereby bringing the fifteen-year reign of the unified Qin Empire to a definitive conclusion.
Historical Evaluation
- Eastern Han political essayist Chen Lin commented in his proclamation: "In former times, a mighty Qin had a weak sovereign; Zhao Gao held the levers of power, exercising despotic authority and meting out fortune or calamity at will. The people of the time were intimidated and dared not speak truthfully; this ultimately resulted in the disaster at Wangyi Palace, the burning and destruction of the ancestral line, and disgrace that remains a perpetual warning to this day."
- Cao Jiong of Cao Wei observed in his Treatise on Six Generations: "Confining himself deep within the palace and delegating governance to slanderous scoundrels, he suffered mutilation at Wangyi; begging merely to live as a commoner, how could such a wish be granted?"
- Tang Dynasty poet Hu Zeng reflected in his verse: "Once Yan Le led the ruthless band, the Second Emperor's court was swept entirely away. Only the waters of the Wei River flow ceaselessly, still winding past Wangyi Palace to this day."
Related Entries
- Battle of Julu
- Pointing to a Deer as a Horse
- Huhai, Second Emperor of Qin
- Zhao Gao
- Ziying
- Liu Bang Enters Xianyang
Bibliography
- Records of the Grand Historian (Shiji), Vol. 6, "Annals of Qin Shi Huang" (Han Dynasty, Sima Qian)
- Records of the Grand Historian (Shiji), Vol. 87, "Biography of Li Si" (Han Dynasty, Sima Qian)
- Comprehensive Mirror to Aid in Government (Zizhi Tongjian), Vol. 9, "Qin Annals III" (Song Dynasty, Sima Guang)
- Book of Han (Hanshu), Vol. 1, "Annals of Emperor Gaozu" (Han Dynasty, Ban Gu)