Anti-intrinsic factor (AIF) antibody testing is a specific serological test to detect the presence of IgG (and rarely IgA) autoantibodies directed against intrinsic factor (IF). Intrinsic factor is secreted by cells in the gastric wall and binds to dietary vitamin B12, allowing its absorption in the terminal part of the small intestine. These antibodies prevent intrinsic factor from binding to B12 or the IF-B12 complex from binding to its receptors in the intestine, leading to malabsorption of the vitamin and consequently megaloblastic anemia.