The Shangjunshu 商君書 "Book of Lord Shang", also called Shangzi 商子 "Master Shang" or Shangjun 商君 "Lord Shang", was written by Gongsun Yang 公孫鞅 or Wei Yang 衛鞅, the Lord of Shang 商君 (390-338 BCE), a title which also gave him the name Shang Yang 商鞅, by which he is commonly known today. Of the original 29 chapters, only 24 are extant. Some chapters were definitely written after Shang Yang's death, either by adherents of himself, or by disciples of Han Fei 韓非, but they reflect his political philosophy which belongs to the school of legalism.
Shang Yang, as advisor of Duke Xiao of Qin 秦孝公 (r. 361-338) during the Warring States period 戰國 (5th cent.-221 BCE), was able to convince his lord of a thorough restructuring of the government and its politics. He advocated the use of a system of reward and punishment to be exerted by a strong and powerful (shi 勢) ruler. The traditional aristocracy was to be replaced by a meritocracy, through which the ruler only employed persons of high abilities. A strong government would rely on only two other classes of people, namely peasants, and soldiers to nourish or to defend the state. The traditional well-field system (jingtianzhi 井田) was abolished and replaced by a system of privat ownership (qianmo 阡陌). Fiefs were to be replaced by commanderies and districts (junxianzhi 郡縣制) directly under the suzerainty of the ruler. Laws and standards (shu 數 "calculation methods") of the whole country should be unified. Shang Yang stressed that each historical age had its own circumstances, and that it was of no used to heedlessly follow the patterns of the past. Adaption to the actual circumstances was in any case a necessary politics. His own age was the age of bureaucracy, in which objective laws had to supersede a personal rulership. The way of aristocratic warfare was also over and had to be replaced by a way of warfare that made use of armies consisting of recruited peasants. The "productive" forces of the whole population thus had to be used for the sake of the state. The peasantry was of an immense importance for the economic wealth and the political power of a state, and therefore it was necessary to care for the opening of new fields to increase agricultural production. The state was governed by means of three mechanisms, first, the laws (fa 法) promulgated by the ruler, second, the trust (xin 信) between the ruler and his highest ministers, and finally the ruler's monopoly on power (quan 權). In order to stimulate the cooperation of the whole society, an all-embracing, absolute and objective system of rewards and punishments had to be made use of. By means of punishment, physical punishment would become superfluous in the end, and laws were to be made in such a mode that they would one day fall into obsolescence.
After the death of of Duke Xiao, Shang Yang became the victim by slandering from the side of the former nobility and was punished with the death penalty by tearing him apart by quartering (chelie 車裂). The reforms were, nonetheless, not revoked and thus contributed to the growing power of the state of Qin.
The oldest extant print of the Shangjunshu was that of Feng Mengzhen's 馮夢楨 Mianmiao Studio 綿眇閣 from the Ming period 明 (1368-1644). There is also a version included in the Cheng Rong's 程榮 collectaneum Han-Wei congshu 漢魏叢書, the version of the Tianyige Library 天一閣, that of Sun Xingyan's 孫星衍 Wenjingtang congshu 問經堂叢書, and the collectanea Ershierzi 二十二子, Zhihai 指海, Zishu baijia 子書百家, and Siku quanshu 四庫全書.
The Shangjunshu attracted the interest of scholars only at a relatively late point of time. The first commentary was thus only written during the Qing period 清 (1644-1911), namely by Yan Wanli 嚴萬里 (Yan Kejun 嚴可均). More recent commentaries were compiled by Wang Shirun 王時潤 (Shangjunshu jiaoquan 商君書斠詮), Zhu Shiche 朱師轍 (Shangjunshu jiegu dingben 商君書解詁定本), Jiang Lihong 蔣禮鴻 (Shangjunshu zhuizhi 商君書錐指) and Gao Heng 高亨 (Shangjunshu zhuyi 商君書注譯).
There is a full translation by J. J. L. Duyvendak (1928), The Book of Lord Shang: a Classic of the Chinese School of Law, San Francisco: Chinese Materials Center.
Li Dingsheng 李定生 (1992). "Shangjunshu 商君書", in: Zhongguo xueshu mingzhu tiyao> 中國學術名著提要, Zhexue 哲學卷, p. 64. Shanghai: Fudan daxue chubanshe.
Pan Fu’en 潘富恩 (1987). "Shangjunshu 商君書", in: Zhongguo da baike quanshu 中國大百科全書, Zhexue 哲學, vol. 2, p. 751. Beijing/Shanghai: Zhongguo da baike quanshu chubanshe.
Pan Fu’en 潘富恩 (1987). "Shang Yang 商鞅, in: Zhongguo da baike quanshu 中國大百科全書, Zhexue 哲學, vol. 2, p. 752. Beijing/Shanghai: Zhongguo da baike quanshu chubanshe.
Yu Dunkang 余敦康 (1992). "Shangjunshu 商君書", in: Zhongguo da baike quanshu 中國大百科全書, Zhongguo lishi 中國歷史, vol. 2, pp. 897-898. Beijing/Shanghai: Zhongguo da baike quanshu chubanshe.
1. 更法 Bianfa The Reform of the Law
2. 墾令 Maoling An Order to Cultivate Waste Lands
3. 農戰 Nongzhan Agriculture and War
4. 去彊 Quqiang The Elimination of Strength
5. 說民 Shuomin About the People
6. 算地 Suandi The Calculation of Land
7. 開塞 Kaisai Opening and Debarring
8. 壹言 Yiyan The Unification of Words
9. 錯法 Cuofa Establishing Laws
10. 戰法 Zhanfa The Method of Warfare
11. 立本 Liben The Establishment of Fundamentals
12. 兵守 Bingshou Military Defense
13. 靳令 Jinling Making Orders Strict
14. 修權 Xiuquan The Cultivation of the Right Standard
15. 徠民 Laimin The Encouragement of Immigration
16. 刑約[缺] Xingyue Compendium of Penalties (lost)
17. 賞刑 Shangxing Reward and Punishments
18. 畫策 Huace Policies
19. 境內 Jingnei Within the borders
20. 弱民 Ruomin Weakening the People
21. [缺] (lost)
22. 外內 Wainei External and Internal Affairs
23. 君臣 Junchen Ruler and Minister
24. 禁使 Jinshi Interdicts and Encouragements
25. 慎法 Shenfa Attention to Law
26. 定分 Dingfen The Fixing of Rights and Duties