The electrophoretic force on a single DNA molecule inside a glass nanocapillary depends on the opening size and varies with the distance along the symmetrical axis of the nanocapillary. Using optical tweezers and DNA-coated beads, we measured the stalling forces and mapped the position-dependent force profiles acting on DNA inside nanocapillaries of different sizes. We showed that the stalling force is higher in nanocapillaries of smaller diameters. The position-dependent force profiles strongly depend on the size of the nanocapillary opening, and for openings smaller than 20 nm, the profiles resemble the behavior observed in solid-state nanopores. To characterize the position-dependent force profiles in nanocapillaries of different sizes, we used a model that combines information from both analytical approximations and numerical calculations.