Pile easily develops necking defects during construction, which can limit the exertion of shaft resistance, resulting in reducing ultimate bearing capacity and creating potential safety hazards to projects. Based on transparent soil technology, this paper took the necking located in the middle part of pile shafts as an example and carried out vertical loading experiments on one intact pile and nine necking piles with caps. Then, the influences of necking length and diameter on the vertical bearing capacity were studied. The speckle field of the soil around piles was processed using the MatPIV program to investigate soil displacement. Through comparison and analysis with the intact pile, the reasons for the reduction in bearing capacity were obtained. The results show that the bearing capacity of the piles is seriously damaged by the necking. When the necking diameter is 4 mm and the necking length is 20 mm, the loss of vertical bearing capacity was 26.6%. The vertical bearing capacity decreases with the increase in necking length or the decrease in necking diameter. Pile necking makes a significant contribution to the displacement of soil around the cap. Inclined downward displacement of soil occurs near necking, which reduces the relative displacement between pile and soil and leads to the loss of pile resistance. For the necking with a large size, the soil displacement at the necking and around the pile cap is connected, which causes the displacement range of the soil under the pile cap to increase, resulting in a weakening of the exertion of shaft resistance. Subsequently, the vertical bearing capacity of piles is reduced.