HPK1 also referred to as MAP4K1, belongs to the category of mammalian STE20-like protein serine/threonine kinases. Its physiological function involves the down-regulation of T cell signals, and it is regarded as a new immune checkpoint of tumor immunology. In this study, we commenced our investigation with the hit compounds, focusing the efforts on structural optimization and SAR exploration to identify a novel class of 2,4-diaminopyrimidine HPK1 inhibitors. Notably, compound 14g exhibited a remarkable inhibitory effect on HPK1 kinase (IC50 = 0.15 nM), significantly suppressed the phosphorylation of the downstream adaptor protein SLP76 (pSLP76 IC50 = 27.92 nM), and effectively stimulated the secretion of the T cell activation marker IL-2 (EC50 = 46.64 nM). In vitro microsomal stability assay, compound 14g showed moderate stability in HLMs with T1/2 = 38.2 min and CLint = 36.4 µL·min−1·mg−1 proteins. In vivo pharmacokinetic studies, compound 14g demonstrated heightened plasma exposure (AUC0-inf = 644 ng·h·mL−1), extended half-life (T1/2 = 9.98 h), and reduced plasma clearance (CL = 52.3 mL·min−1·kg−1) compared to the reference compound after a single intravenous dose of 2 mg/kg in rats. These results indicated that compound 14g emerged as a promising inhibitor of HPK1.