White spot syndrome virus (WSSV) poses a critical threat to crustacean aquaculture, particularly shrimp, causing widespread pandemics. In crustaceans, hemocytes function as a key component of the innate immune system and play a pivotal role in both cellular and humoral immune responses by producing various immune factors, such as antimicrobial peptides (AMPs), to defend against pathogenic microorganisms. In this study, an uncharacterized functional gene named Litopeidin was identified in Pacific white shrimp (Litopenaeus vannamei). It exhibited heightened expression in hemocytes and demonstrated a significant response to WSSV infection. Further, a truncated peptide, Litopeidin28-51, derived from this gene, was characterized and identified as a novel AMP with robust antibacterial and antifungal properties, especially against common aquatic pathogens, including Vibrio spp. Moreover, Litopeidin28-51 significantly suppressed the expression of viral genes (IE1 and VP28, WSSV replication-related genes) and the VP28 protein, as well as reduced viral copy numbers in hematopoietic tissue (Hpt) cells following WSSV infection. Mechanistic studies revealed that Litopeidin28-51 exhibited a direct virucidal effect on WSSV and significantly upregulated immune-related gene expression (including Relish, ALF, Crustin, and LYZ1) in Hpt cells. Notably, in Cherax quadricarinatus and L. vannamei, either co- or pre-treatment with Litopeidin28-51 markedly reduced animal mortality and viral replication in tissues. Collectively, the findings suggest that Litopeidin28-51, a newly identified AMP with potent antibacterial activity, effectively inhibits WSSV replication by disrupting the viral envelope and regulating the cellular antiviral responses, making it a promising candidate for developing anti-infective agents or immunostimulants in aquaculture.