In this work, for nonlinear multi-agent systems, we mainly study distributed doubleintegrator finite-time and fixed-time containment control with undirected heterogeneous networks. At the first, two controllers to realize finite-time containment and two controllers to achieve fixed-time containment were designed. Second, we design appropriate finite-time and fixed-time containment protocols to ensure followers can move to geometric region formed by leaders, and settling time can be estimated. We can obtain that the calculation of convergence time of finite-time containment control is associated to the initial state. And the settling time of the fixed-time containment control is related to the parameters. Finally, correctness of the theory is verified by mathematical simulation experiments.INDEX TERMS Finite-time containment, fixed-time containment, heterogeneous networks, sliding mode control, second-order systems.