COX-2 is crucial for the synthesis of prostaglandins, which are lipid compounds that have diverse roles in inflammation, pain, and fever. Specifically, COX-2 converts arachidonic acid into prostaglandin H2, which is a precursor for other prostaglandins involved in the inflammatory response.