Pistachio is a nut with high consumption that could be affected by aflatoxin contamination, which affects the consumption market; therefore, broad studies seem to be necessary for this area. In the current study, pistachio nuts (Abbasali variety) were coated with different concentrations (0.1%, 0.5%, 1%, and 2%) of methylcellulose (MC) by immersion method and then stored in the incubator (25°C) for four months. The inhibitory effect of hydrocolloid coating on microbial (mold, yeast, and total count) and aflatoxin (B1, B2, G1, G2, and total aflatoxin) contamination, as well as sensory attributes (flavor, color, crispiness, aroma, and total acceptability), was investigated during storage periods. Results showed that the storage period had a significant effect on yeast, mold, and total count. HPLC analysis results showed that coating with MC had a significant inhibitory effect on aflatoxin contamination, and the highest amount of aflatoxin contamination was related to the control sample (3.5%). All samples except sample coated with MC 0.5% had appropriate total acceptability. Regarding the inhibitory effect of MC edible coating on aflatoxin contamination, its application on pistachio nut could be a promising approach to control the fungus infection and reduce aflatoxin production in coated pistachio.