In this paper, the structural and optoelectronic properties of semiconductor NaBePxN1−x (x=0,0.25,0.50,0.75 and 1) alloys in the half-Heusler structure were investigated using density functional theory with GGA approximation. The lattice parameter a, the formation energy Ef and the cohesive energy Ec were examined. The obtained results show that the lattice parameter as a function of x for NaBePxN1−x alloys obeys Vegard’s Law. The negative values of Ef and Ec indicate that NaBeN and NaBeP alloys have thermodynamic stability and strong chemical bonds, implying that they could be synthesized in future experimental research. The estimated optical properties revealed details for NaBePxN1−x alloys concerning the optoelectronic and photovoltaic applications. The high absorption α(x=0,1)≈1.6×106cm−1 and reflectivity coefficients (R(x=0,1)>55%), indicate their suitability for usage in optoelectronic devices. The promising power conversion efficiency (η≈15%) also predicts that the thermodynamically stable alloys NaBeN and NaBeP are good for solar cell applications.