© 2022 IUCr.The title compound, 2C12H10N6·C3H7NO, crystallizes as a racemate in the monoclinic P21/c space group with two independent molecules (I and II) and one dimethylformamide solvent molecule in the asymmetric unit. Both molecules (I and II) have chiral centers at the carbon atoms where the triazine rings of molecules I and II are attached to the phenyl ring. In the crystal, molecules I and II are linked by intermolecular N-H⋯N, N-H⋯O and C-H⋯N hydrogen bonds through the solvent dimethylformamide molecule into layers parallel to (001). In addition, C-H⋯π interactions also connect adjacent molecules into layers parallel to (001). The stability of the molecular packing is ensured by van der Waals interactions between the layers. The Hirshfeld surface analysis indicates that N⋯H/H⋯N (38.3% for I; 35.0% for II), H⋯H (28.2% for I; 27.0% for II) and C⋯H/H⋯C (23.4% for I; 26.3% for II) interactions are the most significant contributors to the crystal packing.