The interaction of alkaline earth metal cations including Be 2+ , Mg 2+ , Ca 2+ , Sr 2+ and Ba 2+ with cyclic peptides containing 3 or 4 (S) alanine molecules (CyAla3 and CyAla4) was investigated by density functional theory (DFT-CAM-B3LYP and DFT-B3LYP). A mixed basis set including 6-31+G(d) for C, H, O, Be 2+ , Mg 2+ , Ca 2+ and LANL2DZ for Sr 2+ and Ba 2+ were used for calculations. The optimized structures, binding energies, and various thermodynamic parameters of free ligands and related metal cation complexes were determined.The order of strength of interaction energies was found as Be 2+ > Mg 2+ > Ca 2+ > Sr 2+ > Ba 2+ . Vibrational frequency calculations showed that the selected cyclic peptides and their complexes with the alkaline earth metal cations were at local minima of their potential energy surfaces. In addition, it was found that the larger cavity CyAla4 ligand, can hold the alkaline metal cations better than CyAla3 molecule when the same metal cation is in the structure of complex. Moreover, analyzing the geometry of [M/CyAla3] 2+ and [M/CyAla4] 2+ complexes indicated that the aggregation with metal cation, caused substantial changes in the geometrical parameters of ligands.