At the end of primitive society, due to the development of production and exchange, there was a division of labor between agriculture, handicrafts and animal husbandry, and professional ethics began to sprout. After entering the class society, there appeared such occupations as commerce, politics, military affairs, education and medical treatment. On the basis of certain social and economic relations, these specific occupations not only require people to have specific knowledge and skills, but also require people to have specific moral concepts, emotions and qualities. In order to safeguard their professional interests and reputation and meet the needs of society, various professional groups have gradually formed professional ethics in their professional practice according to the basic requirements of general social ethics. In ancient literature, there was a long record of professional ethics. For example, Sun Tzu, an ancient art of war in China in the 6th century BC, recorded that "a general is wise, trustworthy, benevolent, brave and strict". Wisdom, faithfulness, benevolence, courage and strictness are called general virtues by ancient China military strategists. The six standards of feudal officials' moral cultivation put forward by the ministers of the Ministry of War in the late Ming Dynasty are called "Six Commandments for Self-examination of People-friendly Officials", which include "Diligent pension, cautious criminal law, no bribery, strict expropriation and frugality". Ancient doctors in China have formed a fine tradition of medical ethics in their long-term medical practice. It is a long-standing medical motto in the medical field that "the sick are not cloud, the easy things are not difficult, the rich and the poor agree, and the expensive and the cheap have different medicines".
The Hippocratic Oath in ancient Greece in the 5th century BC is the earliest medical professional ethics document in the West. The professional ethics of a certain society is determined and restricted by the division of labor and economic system of that society.
In feudal society, the self-sufficient natural economy and feudal hierarchy not only restricted the communication between occupations, but also hindered the development of professional ethics. Only the rules and regulations of some industrial and commercial associations and the words, deeds and works of famous people engaged in medical, educational, political and military industries contain professional ethics. In this social industry, there are also people with superb skills and noble morality. Their professional ethics behavior and quality have been praised by the masses, attacked from generation to generation, and gradually formed a fine professional ethics tradition. The development of capitalist commodity economy has promoted the expansion of social division of labor, and occupations and industries are also increasing and complicated. In order to enhance their competitiveness and increase profits, various professional organizations advocate professional ethics one after another to improve their professional reputation. Many countries and regions have also established professional associations, formulated articles of association, and stipulated professional purposes and professional ethics. So as to promote the popularization and development of professional ethics. In capitalist society, not only the morals of generals, officials, medical ethics and teachers' style have been further enriched and improved, but also many morals that were not available in previous society have emerged, such as enterprise ethics, business ethics, lawyer ethics, scientific ethics, editor ethics, writer ethics, painter ethics, sports ethics and so on. However, due to bourgeois egoism and the concept of money first, the role of professional ethics has been greatly limited in capitalist society. Because of the nature of capitalist society, some professional ethics are hypocritical. Advocating when necessary, trampling when unnecessary, often superficial and boastful.