In the mol-ecule of the title compound, C(21)H(20)BrN(3)O(3), the pyrimidine ring is oriented at dihedral angles of 80.87 (3) and 15.99 (3)°, respectively, to the pyrimidine and bromo-phenyl rings. The dihedral angle between the two benzene rings is 88.37 (3)°. In the crystal structure, inter-molecular N-H⋯O and O-H⋯N hydrogen bonds link the mol-ecules. A π-π contact between pyrimidine and phenyl rings [centroid-centroid distance = 3.776 (3) Å] may further stabilize the structure. The methine H and the methyl C and H atoms are disordered over two positions and were refined with occupancies of 0.522 (13) and 0.478 (13).