Catalyzes the addition of N-acetylglucosamine (GlcNAc) in beta 1-6 linkage to the alpha-linked mannose of biantennary N-linked oligosaccharides (PubMed:10700233, PubMed:14561752, PubMed:22715095). Catalyzes an important step in the biosynthesis of branched, complex-type N-glycans, such as those found on EGFR, TGFR (TGF-beta receptor) and CDH2 (PubMed:12122020, PubMed:10700233, PubMed:14561752, PubMed:15459394, PubMed:22715095). Via its role in the biosynthesis of complex N-glycans, plays an important role in the activation of cellular signaling pathways, reorganization of the actin cytoskeleton, cell-cell adhesion and cell migration (PubMed:10700233, PubMed:14561752, PubMed:15459394). MGAT5-dependent EGFR N-glycosylation enhances the interaction between EGFR and LGALS3 and thereby prevents rapid EGFR endocytosis and prolongs EGFR signaling (PubMed:15459394). Required for efficient interaction between TGFB1 and its receptor (PubMed:15459394). Enhances activation of intracellular signaling pathways by several types of growth factors, including FGF2, PDGF, IGF, TGFB1 and EGF (PubMed:15459394). MGAT5-dependent CDH2 N-glycosylation inhibits CDH2-mediated homotypic cell-cell adhesion and contributes to the regulation of downstream signaling pathways (PubMed:14561752). Promotes cell migration (PubMed:14561752, PubMed:15459394). Contributes to the regulation of the inflammatory response (PubMed:11217864, PubMed:15459394). MGAT5-dependent TCR N-glycosylation enhances the interaction between TCR and LGALS3, limits agonist-induced TCR clustering, and thereby dampens TCR-mediated responses to antigens (PubMed:11217864). Required for normal leukocyte evasation and accumulation at sites of inflammation (PubMed:15459394). Inhibits attachment of monocytes to the vascular endothelium and subsequent monocyte diapedesis (By similarity). Promotes proliferation of umbilical vein endothelial cells and angiogenesis, at least in part by promoting the release of the growth factor FGF2 from the extracellular matrix. N(4)-{beta-D-GlcNAc-(1->2)-[beta-D-GlcNAc-(1->4)]-alpha-D-Man-(1->3)-[beta-D-GlcNAc-(1->2)-alpha-D-Man-(1->6)]-beta-D-Man-(1->4)-beta-D-GlcNAcl-(1->4)-beta-D-GlcNAc}-L-asparaginyl-[protein] + UDP-N-acetyl-alpha-D-glucosamine = H(+) + N(4)-{beta-D-GlcNAc-(1->2)-[beta-D-GlcNAc-(1->4)]-alpha-D-Man-(1->3)-[beta-D-GlcNAc-(1->2)-[beta-D-GlcNAc-(1->6)]-alpha-D-Man-(1->6)]-beta-D-Man-(1->4)-beta-D-GlcNAcl-(1->4)-beta-D-GlcNAc}-L-asparaginyl-[protein] + UDP Protein modification; protein glycosylation. Detected in cerebellum. N-glycosylated. A secreted form is released from the membrane after cleavage by gamma-secretase. Mice are born at the expected Mendelian rate and have no visible phenotype at birth. Adult mice display abnormal leukocyte recruitment to inflamed tissues, hypersensitivity of T cells to agonists that activate T cell receptors, an age-related decrease in the cellularity of kidney glomeruli and a tendency to develop proliferative glomerulonephritis, plus defective nurturing behavior (PubMed:10700233, PubMed:11217864). Mutant mice show increased responsiveness to treatments that cause delayed-type hypersensitivity (PubMed:11217864). Mice show increased incidence of autoimmune encephalomyelitis in response to injections with MBP (PubMed:11217864). Transgenic mice that express polyomavirus middle T antigen develop mammary tumors; 50% of female wild-type mice have detectable tumors after 16 weeks, but it takes 24 weeks until 50% of the female mice that lack Mgat5 develop mammary tumors. Male mice that express polyomavirus middle T antigen develop mammary tumors after 6 to 9 months; males that lack Mgat5 develop tumors after 10 to 13 months. Formation of lung metastases is about 5% of wild-type (PubMed:10700233). Tumor initiation is not decreased in mice that lack Mgat5, but tumor growth is strongly decreased (PubMed:10700233). Tumor cells from mutant mice show impaired membrane ruffling, probably due to decreased activation of phosphoinositide-3-kinase (PI3K) (PubMed:10700233). Embryonic fibroblasts from Mgat5-deficient mice display increased Cdh2-mediated cell-cell adhesion (PubMed:14561752). Mutant mice that lack both Mgat5 and Mgat5b display no visible changes in brain anatomy, but their brains display defective biosynthesis of both O-mannosyl glycans and N-linked glycans (PubMed:22715095). Belongs to the glycosyltransferase 18 family.