Infection with the pathogenic bacterium Vibrio parahaemolyticus typically causes severe hepatopancreatic damage in Penaeus vannamei, often resulting in acute shrimp mortality. Therefore, protecting the shrimp’s hepatopancreas is crucial for enhancing their disease resistance. Previous research has demonstrated that the probiotic strain Lactobacillus plantarum Ep-M17 inhibits the growth of V. parahaemolyticus E1 in vitro. However, it remains uncertain whether Ep-M17 can provide protective benefits to the shrimp’s hepatopancreas. To address this knowledge gap, our present study investigated the histological changes, enzyme activity, gene transcription, and metabolite levels in the hepatopancreas of shrimp after a 4-week diet supplemented with Ep-M17. The results revealed that incorporating Ep-M17 into the shrimp’s diet alleviated the damage by V. parahaemolyticus E1 infection in hepatopancreatic cells. In addition, the inclusion of Ep-M17 notably boosted the effectiveness of immunodigestive enzymes such as SOD, AKP, and CAT. Furthermore, Ep-M17 stimulated gene transcription in crucial immune response-related signalling pathways like the mitogen-activated protein kinase signaling pathway and the antigen processing and presentation pathway. Moreover, the incorporation of Ep-M17 into shrimp diets increased the levels of β-alanine, and histidine in the hepatopancreas, enhancing anti-inflammatory capacity and improving the shrimp’s immune response. Overall, the results indicate that incorporating Ep-M17 into the diet can enhance shrimp disease resistance by bolstering both immune response and metabolic activity within the hepatopancreas. These results underscore the importance of probiotics in controlling aquatic animal diseases and highlight Ep-M17 as a promising dietary supplement for enhancing shrimp health and immunity in aquaculture.