Heparan sulfate is a polysaccharide that plays essential physiological functions in the animal kingdom. Heparin, a highly sulfated form of heparan sulfate, is a widely prescribed anticoagulant drug worldwide. The heparan sulfate and heparin isolated from natural sources are highly heterogeneous mixtures differing in their polysaccharide chain lengths and sulfation patterns. The access to structurally defined heparan sulfate and heparin is critical to probe the contribution of specific sulfated saccharide structures to the biological functions as well as for the development of the next generation of heparin-based anticoagulant drugs. The synthesis of heparan sulfate and heparin, using a purely chemical approach, has proven extremely difficult, especially for targets larger than octasaccharides having a high degree of site-specific sulfation. A new chemoenzymatic method has emerged as an effective alternative approach. This method uses recombinant heparan sulfate biosynthetic enzymes combined with unnatural uridine diphosphate-monosaccharide donors. Recent examples demonstrate the successful synthesis of ultra-low molecular weight heparin, low-molecular weight heparin and bioengineered heparin with unprecedented efficiency. The new method provides an opportunity to develop improved heparin-based therapeutics.