A theoretical study based on DFT-LDA of the structural, electronic, and magnetic properties of the new substitution CaFe2B2 compound derived from BaFe2As2 is presented. Through a relaxation calculation, we found that this compound crystallizes in tetragonal and orthorhombic phases. Formation energies, lattice parameters, density of states, and magnetic moments are calculated. The ground state for this compound is nonmagnetic (NM). As for the anti-ferromagnetic state, more formation energy is characterized by large magnetic moment on each Fe atoms for AFM spin configuration. The results are compared with previous calculations and experimental data. The results of electronic and magnetic properties show that the partial and total density of states for NM, FM, and AFM phases are characterized by strong hybridization between Fe and B atoms. The energy band structure indicates the presence of overlapping valence and conduction bands at the Fermi level. The analyses of charge densities show that the type of bonding in the CaFe2B2 compound is metallic. An important resemblance with the original compound is observed which leads us to think that this compound is maybe a superconducting material.