Iron-containing and iron-free 15N labeled polyanilines were prepared as a precursor of N-doped carbon electrochemical oxygen reduction catalysts in polymer electrolyte fuel cells (PEFCs) and were pyrolyzed at several different temperatures in a nitrogen atmosphere. The oxygen reduction reaction was evaluated by rotating disk electrode experiments, and XPS and 15N solid-state NMR spectra of the samples were measured. The relationship between oxygen reduction activity and the chemical structure, combined with principal component analysis was discussed. Using principal component analysis of the XPS N1s spectra and 15N solid-state NMR spectra, it is found that most pyridinic, graphitic, and pyrrolic nitrogen atoms which are similar part of nitrogen in all catalysts are not related to oxygen reduction reaction. However, the catalysts which contain a larger proportion of the particular type of pyridinic nitrogen atoms (FeNx) instead of pyrrolic nitrogen atoms show a higher activity for the oxygen reduction reaction.