Kant's first formulation of his mature theory of the sublime is to be found in the Groundwork of the Metaphysic of Morals (1785) and the Critique of Practical Reason (1788). In order to understand this theory, I shall begin with a more detailed exposition of Kant's position on morality.
First, we will remember from the preceding chapter that, for Kant, moral decision is inaugurated by the rational and autonomous supersensible self. It is, however, important to note that, because the rational self is conjoined with a phenomenal counterpart, the latter tends to inhibit the workings of the former. This means that the principles which inform our moral decisions are influenced by potentially distracting feelings and desires, and we can, in consequence, only act in an imperfectly rational way. We do not (as a wholly rational being would) necessarily adopt the principle of action which the realization of some specific end objectively demands. 1 This is why Kant holds that our willing of ends is always expressible in the form of hypothetical or categorical imperatives. The former are conditional, and take the form of 'If I want x, then I ought to do y'. In such cases our principle of action is determined by an end that is contingent upon a particular desire (i.e. an end derived from our phenomenal being). A categorical imperative, in contrast, is unconditional, and simply takes the form 'I ought to do y'. Here our principle of action is determined fundamentally not by some empirical end, but by the demands of reason itself. As Kant puts it:
It is concerned, not with the matter of the action and its presumed results, but with its form and with the principle from which it follows: and what is essentially good in the action consists in the mental disposition, let the consequences be what they may. This imperative may be called the imperative of morality. 2