Biliary atresia (BA) is a devastating inflammatory and fibrosing cholangiopathy of neonates with unknown aetiology. We aim to investigate the relationship between these two main characteristics. Single-cell RNA sequencing and spatial transcriptomics were performed on liver samples from a cohort of 14 objects (BA: n = 6; control: n = 8). We conducted data integration and cell-type annotation based on gene expression profiling. Furthermore, we identified fibrosis-related immune cells according to their spatial locations, GO and KEGG analysis. Finally, SPOTlight and CIBERSORTx were used to deconvolute ST data and microarray data of the GSE46960 cohorts, respectively. Immune subpopulations inhabiting the 'fibrotic niche' (areas of scarring), comprising 'intermediate' CD14++ CD16+ monocytes, scar-associated macrophages, natural killer T cells, transitional B cells and FCN3+ neutrophils were identified. GO and KEGG analyses showed that pathways including 'positive regulation of smooth muscle cell/fibroblast proliferation' and 'positive regulation of/response to VEGFR/VEGF/EGFR/FGF' were enriched in these cell types. Interactions analysis showed that communication among 'FGF_FGFR', 'RPS19-C5AR1', 'CD74_COPA/MIF/APP' and 'TNFRSF1A/B_GRN' was extensive. Finally, the results of deconvolution for ST data and microarray data validated that the proportions of certain identified fibrosis-related cell types we identified were increased in BA. Fibrosis is an important feature of BA, in which the immune system plays an important role. Our work reveals the subpopulations of immune cells enriched in the fibrotic niche of BA liver, as well as key related pathways and molecules; some are highlighted for the first time in liver fibrosis. These newly identified interactions might partly explain why the rate of liver fibrosis occurs much faster in BA than in other liver diseases. Our study revealed the molecular, cellular and spatial immune microenvironment of the fibrotic niche of BA.