In this paper, N-arylations between two heteroaryl compounds were studied. Conditions were found to generate selectively either 3- or 5-heteroarylamino-1,2,4-triazines by investigating anionic processes (use of bases such as 2,2',6,6'-tetramethylpiperidine/tBuOK/nBuLi) or Pd-catalyzed N-arylations [Pd(OAc)(2), xantphos]. These methods were successfully applied to a wide variety of heteroarylamines and allowed us to pursue our work on fused polynitrogen compounds synthesis.