Myxococcus xanthus is a model bacterium to study social behavior. At the cellular level, the different social behaviors of M. xanthus involve extensive cell–cell contacts. Here, we used bioinformatics, genetics, heterologous expression and biochemical experiments to identify and characterize the key enzymes in M. xanthus implicated in O-antigen and lipopolysaccharide (LPS) biosynthesis and examined the role of LPS O-antigen in M. xanthus social behaviors. We identified WbaPMx (MXAN_2922) as the polyisoprenyl-phosphate hexose-1-phosphate transferase responsible for priming O-antigen synthesis. In heterologous expression experiments, WbaPMx complemented a Salmonella enterica mutant lacking the endogenous WbaP that primes O-antigen synthesis, indicating that WbaPMx transfers galactose-1-P to undecaprenyl-phosphate. We also identified WaaLMx (MXAN_2919), as the O-antigen ligase that joins O-antigen to lipid A-core. Our data also support the previous suggestion that WzmMx (MXAN_4622) and WztMx (MXAN_4623) form the Wzm/Wzt ABC transporter. We show that mutations that block different steps in LPS O-antigen synthesis can cause pleiotropic phenotypes. Also, using a wbaPMx deletion mutant, we revisited the role of LPS O-antigen and demonstrate that it is important for gliding motility, conditionally important for type IV pili-dependent motility and required to complete the developmental program leading to the formation of spore-filled fruiting bodies.