It is demonstrated that the NEXAFS spectra are a "fingerprint" of the micro
structure and the composition of the AlGaN and InGaN alloys. From the angul
ar dependence of the NEXAFS spectra, the hexagonal symmetry of the compound
s under study is deduced and the (p(x,) p(y)) or p(z) character of the fina
l state is identified. The energy position of the absorption edge (E-abs) O
f the binary compounds depends on the cation atomic number. The Eabs Of the
AlGaN alloys takes values in between those corresponding to AlN and GaN; a
s was expected. Contrary to that the absorption edge of In0.16Ga0.84N is re
d-shifted relative to that of GaN and InN, probably due to ordering and/or
phase separation phenomena.