Infrared small target detection is one of the vital tasks in various infrared detection application, and has some typical challenges such as small and dim target, background noise, and complex scenes. To address the problem, a context guided reverse attention network (CgraNet) is proposed to detect infrared small target by introducing context guided module (CGM), multiscale aggregation block (MAB), and reverse attention module (RAM). The CGM is designed to capture inherent property of semantic information from multi-scale encode layer in pixel-level recognition. In order to eliminate the impact of low-level feature on computational complexity and ensure the detection performance, we design the MAB to aggregate multiscale feature. The RAM is integrated in decoder layer to combine the features from MAB and CGM for fusing the localization information and multiscale structural information. Extensive experiments on infrared small target datasets demonstrate that our method can achieve high detection accuracy and low false alarm rate compared with some state-of-the-art model-driven and datadriven methods.