With the emergence of several infectious diseases in shrimp aquaculture, there is a growing interest in the use of feed additives to enhance shrimp immunity. Recently, the use of 5-aminolevulinic acid (5-ALA), a non-protein amino acid that plays a rate-limiting role in heme biosynthesis, has received attention for its positive effect on immunity in livestock animals. To evaluate the effect of 5-ALA in the Pacific white shrimp, Litopenaeus vannamei, we conducted microarray analysis, a Vibrio parahaemolyticus immersion challenge test, an ATP level assay, and gene expression analysis of some hemoproteins and genes associated with heme synthesis and degradation. Out of 15,745 L. vannamei putative genes on the microarray, 101 genes were differentially expressed by more than fourfold (p < 0.05) between 5-ALA-supplemented and control shrimp hepatopancreas. 5-ALA upregulated 99 of the 101 genes, 41 of which were immune- and defense-related genes based on sequence homology. Compared to the control, the 5-ALA-supplemented group had a higher survival rate in the challenge test, higher transcript levels of porphobilinogen synthase, ferrochelatase, catalase, nuclear receptor E75, and heme oxygenase-1 and higher levels of ATP. These findings suggest that dietary 5-ALA enhanced the immune response of L. vannamei to V. parahaemolyticus, upregulated immune- and defense-related genes, and enhanced aerobic energy metabolism, respectively. Further studies are needed to elucidate the extent of 5-ALA use in shrimp culture.