Galactopyranosides with aryl-aminopyrimidine moieties at O3 inhibit the tumor and immunity-related galectin-3 with high selectivity over other galectins. Here, LGALS3 is linked to neoplasm.