Substance use disorders (SUDs) represent a significant public health crisis. Worldwide, 5.4% of the global disease burden is attributed to SUDs and alcohol use, and many more use psychoactive substances recreationally. Often associated with comorbidities, SUDs result in changes to both brain function and physiological responses. Mounting evidence calls for a precision approach for the treatment and diagnosis of SUDs, and the gut microbiome is emerging as a contributor to such disorders. Over the last few centuries, modern lifestyles, diets, and medical care have altered the health of the microbes that live in and on our bodies; as we develop, our diets and lifestyle dictate which microbes flourish and which microbes vanish. An increase in antibiotic treatments, with many antibiotic interventions occurring early in life during the microbiome's normal development, transforms developing microbial communities. Links have been made between the microbiome and SUDs, and the microbiome and conditions that are often comorbid with SUDs such as anxiety, depression, pain, and stress. A better understanding of the mechanisms influencing behavioral changes and drug use is critical in developing novel treatments for SUDSs. Targeting the microbiome as a therapeutic and diagnostic tool is a promising avenue of exploration. This review will provide an overview of the role of the gut-brain axis in a wide range of SUDs, discuss host and microbe pathways that mediate changes in the brain's response to drugs, and the microbes and related metabolites that impact behavior and health within the gut-brain axis.