Although Confucius did not believe in Democracy, or at least did not advocate for it, he was opposed to the idea of hereditary monarchy and put forth a theory of government based (not in so many words) on the idea of a social contract. The ruler was obligated to provide for his people and set a moral example, and in turn the people owed their ruler filial piety just as they would towards their own father. The ruler was the father of the state, but his authority rested on the consent of the governed. Government exists by the will of the governed. As Confucius put it:
"The superior man does not use rewards, yet the people are stimulated to virtue. He does not show wrath, yet the people are more awed than by hatchets and battle-axes." (Doctrine of the Mean, c. xxxiii., v. 4.)
Furthermore, "When a prince#39;s personal conduct is correct, his government is effective without the issuing of orders. When his personal conduct is not correct, he may issue orders but they will not be obeyed." (Bk. xiii., c. vi.)
The people are the foundation of the state and government authority. "The people are the root of a country." (Pt. iii., bk. iii.) And in the same book, the great ruler, Shun, is reported as saying: "Of all who are to be feared, are not the people the chief?" (Pt. ii., bk. ii., 2.)
It was the duty of ministers to speak out against the ruler if he engaged in wrong conduct and even depose him if necessary. "If the prince have great faults, they ought to remonstrate with him; and, if he do not listen to them after they have done so again and again, they ought to depose him.' (Bk. v., pt. ii., c. ix., v. I.)
And, in extreme, cases the people were justified in killing their sovereign. Mencius expressed the principle of the right to depose tyrants in this clever way:
"The king asked: 'May a minister put his sovereign to death?'
"Mencius said; 'He who outrages benevolence is called a robber; he who outrages righteousness, is called a ruffian. The robber and ruffian we call a mere fellow. I have heard of the execution of the fellow, Chow, but I have not so heard of one#39;s sovereign being put to death.'" (Bk. i., pt. ii., c. viii.)
In other words, it was not right to kill a king but it was justified to kill a robber, and an immoral rapacious kind was not a king but a mere robber.