The exclusion mechanism of food contaminants such as bisphenol A (BPA), Flavonoids (FLA), and Goitrin (GOI) onto the novel gallium–metal organic framework (MOF) and functionalized MOF with oxalamide group (MOF-OX) is evaluated by utilizing molecular dynamics (MD) and Metadynamics simulations. The atoms in molecules (AIM) analysis detected different types of atomic interactions between contaminant molecules and substrates. To assess this procedure, a range of descriptors including interaction energies, root mean square displacement, radial distribution function (RDF), density, hydrogen bond count (HB), and contact numbers are examined across the simulation trajectories. The most important elements in the stability of the systems under examination are found to be stacking π–π and HB interactions. It was confirmed by a significant value of total interaction energy for BPA/MOF-OX (− 338.21 kJ mol
−1
) and BPA/MOF (− 389.95 kJ mol
−1
) complexes. Evaluation of interaction energies reveals that L–J interaction plays an essential role in the adsorption of food contaminants on the substrates. The free energy values for the stability systems of BPA/MOF and BPA/MOF-OX complexes at their global minima reached about BPA/MOF = − 254.29 kJ mol
−1
and BPA/MOF-OX = − 187.62 kJ mol
−1
, respectively. Nevertheless, this work provides a new strategy for the preparation of a new hierarchical tree-dimensional of the Ga-MOF hybrid material for the adsorption and exclusion of food contaminates and their effect on human health.