First-principles calculations employing the density functional theory full-potential (linearized) augmented plane-wave plus local orbitals (FP-(L)/APW + lo) method were conducted to investigate the structural, electronic and optical characteristics of silver-based ternary oxides XAgO (X = Li, Na, K, and Rb). The GGA-PBEsol and TB-mBJ functionals were employed to describe the exchange-correlation potential. The optimized lattice parameters and atomic positions obtained from the calculations exhibit good agreement with both theoretical predictions and experimental measurements. Various exchange-correlation functionals were employed to evaluate the electronic properties, revealing that the newly developed Tran–Blaha modified Becke–Johnson functional yields a significant improvement in the band gap value. All XAgO compounds under consideration are categorized as semiconductor materials where the band gap value decreases as the atomic size of the X element increases. The study also explored the total and site-projected l-decomposed densities of states. Additionally, the complex dielectric function, refractive index, extinction coefficient, reflectivity, and loss function spectra were calculated for the incident radiation polarized parallel to both the [100] and [001] crystalline directions. The interband transitions that contribute effectively to the observed peaks in the imaginary part of the dielectric function were identified.