In this paper structural and electronic properties of AgGaX2 (X=S, Se) compounds in bulk and its nanolayers in [112] direction were calculated by using Full Potential Linear Augmented Plane Wave (FP-LAPW) based on density functional theory. The studied nanolayer were confined in the orthorhombic supercell and simulated in [112] direction. All calculations were done by applying the periodic boundary condition along nanolayer surfaces, for example x and y Cartesian coordinate and enough vacuum were provided to isolate the system from its neighbors. For investigation of structural and electronic properties of bulk and nano-layers several approximation were used and the results were in good agreement to the experiment and all materials were semiconductors. The effects of dangling bonds and nanolayer thickness on the electronic properties were explored, also cohesive energy were calculated to investigate the structural stability.