“The only purpose for which power can be rightfully exercised over any member of a civilized community, against his will, is to prevent harm to others.” – John Stuart Mill. The above sentence has been the one significant principle as asserted by Mill in his famous On Liberty, commonly called the “harm principle”. Harm, in his context, means only direct harm, by means of actions and inaction, onto others. Harm that one done to others by harming himself does not count unless one has failed to fulfil some specific and concrete obligation that ought to be done initially. Interference should not be placed on someone as long as the things done do not harm others. Legal penalties and sanctions can only be justified if they are imposed to prevent harm to others.
Mill mentioned that the time where the society or the individual as a whole can impose influences on particular individual liberty is when it is for self-protection. If a person is placing himself in a position that is dangerous solely to him, society has no right to interfere. He believes that every individual is autonomous, nothing can be compelled upon him/her, for his/her own benefit/welfare, as long as the thing done does not impose threats to others even though it is harming himself. This is what Mill meant from “Over himself, over his own body and mind, the individual is sovereign”  . However, this does not apply to children and some “backward states of society”, who are not capable to take care of themselves and to make sensible decisions, such as the undeveloped races.
Furthermore, Mill thought that human liberty should encompass first, the inward domain of conscience, and liberty of thought and feeling. Second, the liberty of tastes and pursuits in planning one’s own life and lastly, the liberty of individuals in uniting with other consenting collective groups for any purposes which do not harm others. He believed that a good society can only exist through the granting of all the liberties to the people in pursuing their own good lives in their own good ways. 
In Mill’s works, they were inevitably much influenced by his thought on utilitarianism  . Obviously, in which he regarded “utility as the ultimate appeal on all ethical questions…in the largest sense, grounded on the permanent interests of man…”  Utility, or the Greatest Happiness Principle, would be the permanent interests of mankind. This can be seen much clearer where he held that “actions are right in proportion as they tend to promote happiness, wrong as they tend to produce the reverse of happiness”. 
What did the legal theorists think?
In an influential defence of the harm principle, Raz has challenged on the precept on how the state should promote the well-being of people and in the pursuit of moral ideas, how far, the state in coercing the society should be determined by the harm principle. He suggested that it is a perfectionist ideal which presupposes specific moral conceptions which are not indifferent towards criteria of moral worth or moral virtue  .
Also, as we have seen, Mill ruled out the compulsion and control of the state to prevent harmless wrongdoing although that could be what the state think is in the best interest of the society in obtaining pleasures and happiness. By acting as a guiding principle in terms of political restraint, this will not lead Raz to non-perfectionist position  .
Raz supported Mill’s harm principle not by his utilitarian path, but by the autonomy principle. He claimed that the autonomy principle is an important ingredient for the state to pursue a moral good and to promote a good life for the citizens in such societies. ‘Autonomous life is valuable only if it is spent in the pursuit of acceptable and valuable projects and relationships.’ 
Ultimately, Raz’s central claim is to defend the harm principle through the principle of autonomy for one simple reason: ‘The means used, coercive interference, violates the autonomy of its victim’ because ‘it violates the condition of independence and expresses a relation of domination and an attitude of disrespect for the coerced individual and, coercion by criminal penalties is a global and indiscriminate invasion of autonomy.’  To complete a personal autonomy, condition of independence  must be present, too. Slavery, moral censorship, sale of contraceptives  , etc could be the more common examples.
Dan-Cohen has also come out with a similar structure of Raz’s arguments on the harm principle but a rather more different and inconsistent conclusion, in which he focused more on criminal law. He suggested that the harm principle should be replaced by the dignity principle  because dignity demands ‘that our actions, practices, and institutions convey an attitude of respect to people.’  He has made a hypothetical example of ‘happy slavery’ in contradicting with Raz’s argument on the independence is part and parcel of autonomy but his point is, a dignity principle altogether independent of autonomy.