Effectively laying the groundwork for his later work in economics, Smith in The Theory of Moral Sentiments sets forth a theory of how we come to be moral, of how this morality functions on both individual and societal levels, and of what forces are likely to corrupt our sense of morality.
The main point that Smith makes is that our sense of morality is derived from our capacity to sympathize directly and indirectly with other people. We wish both to be praised and to be worthy of this praise, as well as to avoid both blame and blame-worthiness. On account of these interests, we must learn to temper our reactions to other people, as well as our reactions to fortune: we are naturally more interested in our own affairs than anyone else is. Our actions are liable to become overblown and unacceptable unless we temper our egos and see ourselves in the same light in which society at large sees us. Fortunately, we are able to achieve this moral perspective because of our consciences, which allow us to envision our own actions just as a disinterested observer might.
As is made evident in The Theory of Moral Sentiments, Smith believes in a benevolent and omniscient God, and concludes from this belief that our behavior is inherently moral. Since God designed the universe like a watch, with each individual component working in harmony with all the others to make the mechanism run beautifully, it follows that God designed our behavior with the ultimate end of divine goodness in mind. This is how Smith justifies setting forward a theory which describes how our morality functions, as opposed to a theory which prescribes certain behaviors that signify moral actions: he believes that our most fundamental nature, instilled in us by God, is moral.
Though we are inherently moral, Smith warns that there are external sources of corruption which can distort our morals, leading us to behave immorally. Chief among these sources is the influence of the upper class, whose place in the public eye can warp the public's behavior. People want to be accepted and approved of by society, and there appear to be two ways to attain such approval: to be wise and virtuous, or to be wealthy and of high status. People are therefore prone to conflate wealth and status with virtue, and will blindly pursue wealth as a result. Moreover, those upper-class people who receive popular approval feel themselves justified in actions which would otherwise appear morally suspect, because the public is likely to approve of these individuals unless their actions are truly horrific. Thus, the fashions established by the upper class, as well as the customs of society, tend to distort our perceptions of aesthetic goodness and, to a lesser degree, of morality.
Corruption notwithstanding, Smith believes that class stratification is part of God's design. Though we ought to work diligently to advance ourselves, Smith says that there are limits to human endeavor; if we repeatedly meet with failure to advance, we ought to consider that our current places in society might be the proper places designated for us by God. Smith also believes that allowing the rich to pursue their own interests provides the best possible outcome for all classes, because the rich cannot actually consume that much more than other people; therefore, the excess resources and pleasures end up being indirectly distributed among those lower-class people who worked to produce these goods. This is what Smith famously describes using the metaphor of "an invisible hand": people who pursue their own interests ultimately produce the optimal level of wealth for all of society (182).
Smith concludes The Theory of Moral Sentiments by considering what constitutes virtue, and what ought to be "the practical rules of morality." Smith believes that virtue comes from a combination of propriety, benevolence, and prudence, which are all recommended to us by our sympathetic capacity and by our desire to receive society's approval. By experiencing specific instances of moral or immoral action, directly or indirectly, we come to form general moral principles which constitute a moral code, as it were. In terms of practical rules, Smith distinguishes between justice and all other virtues, since justice consists of respecting both others and ourselves by not inflicting certain immoral actions upon others. It is the only virtue which can be enforced and punished when it is breached. Other virtues, when breached, though they cause the disapproval of observers, do not merit punishment; moreover, the propriety of these other virtues is so case specific that it would be futile to try to arrive at a general system of rules for these virtues. Thus, the practical rules of morality should only cover justice -- what is called "jurisprudence" (330).