Cinnamaldehyde exhibits potent antibacterial activity, yet its mechanism against Bacillus cereus and its stability in use remain understudied. Herein, this study aimed to investigate the antibacterial mechanism of cinnamaldehyde against B. cereus and to prepare cinnamaldehyde nanoemulsions by ultrasonic emulsification to improve its stability. Cinnamaldehyde exhibited significant antibacterial effects on B. cereus by destroying the integrity of the cell wall and membrane, interfering with normal metabolic activities, inhibiting swarming motility, destroying the structure of the biofilm, and inhibiting enterotoxin production. Furthermore, the nanoemulsion had the smallest mean particle size and PDI at 6% sodium caseinate (SC) and 1% medium chain triglyceride (MCT). FTIR results showed that cinnamaldehyde was successfully encapsulated in the nanoemulsion. Cinnamaldehyde in nanoemulsions exhibited a slow and sustained release behavior. The antibacterial and storage stability tests showed that after emulsification, the minimum inhibition concentration (MIC) and minimum bactericidal concentration (MBC) against B. cereus were 0.82 times higher than those of free cinnamaldehyde, and its particle size remained at under 200 nm after storage at 4 degrees C and 25 degrees C for 15 days. Finally, cinnamaldehyde nanoemulsions demonstrated excellent antibacterial potential in whole, low-fat, and skim milk, underscoring cinnamaldehyde's viability as a natural preservative in food systems. This investigation might provide a novel strategy for the practical utilization of cinnamaldehyde in the preservation of foodstuffs.