This work presents the O K - and Ti L3,2 -edge x-ray absorption near-edge structure (XANES) spectra of Pbx Sr1-x Ti O3 (Px STO) and Bax Sr1-x Ti O3 (Bx STO) compounds with various Pb and Ba concentrations. The result provides direct evidence that the Pb-O bonding strongly affects O 2p-Ti 3d hybridization in the Ti O6 octahedron of Px STO. In contrast, the Ba-O bonding does not substantially affect O 2p-Ti 3d hybridization in Bx STO. The Ti L3 -edge XANES spectra show the splitting of the eg band for Px STO with x≳0.5, which provides an evidence of Pb-induced tetragonal distortion in the Ti O6 octahedron. In contrast, eg band splitting is absent in Bx STO.