The objective of the present study was to investigate the antifungal activities of aqueous and ethanol extracts of Persian shallot (Allium hirtifolium Boiss) combined with potassium sorbate against Aspergillus flavus and Penicillium citrinum. Chemical analysis of the extracts was conducted using gas chromatography/mass spectrometry (GC/MS). Antifungal activity was assessed using agar well diffusion, mycelial growth inhibition, minimal inhibitory concentration (MIC), and fractional inhibitory concentration (FIC) methods. The main component of the extracts were methyl methylthiomethyl disulfide and 1‐Butene, 1‐(methylthio)‐(Z). Both extracts completely inhibited the mycelial growth of A flavus. MIC value of aqueous and ethanol extracts of Persian shallot against A flavus was 10 and 5 mg/mL, respectively. MIC value of both extracts against P citrinum was 2.5 mg/mL. Synergistic antifungal activity (FICi = 0.5) was found between aqueous extract of Persian shallot and potassium sorbate against A flavus. In conclusion, aqueous extract of Persian shallot has the potential to be used as an adjunct natural antifungal to reduce the concentration of potassium sorbate in foods.