A polyaxial bone anchoring device is provided including a bone anchoring element (1) having a shank (2) for anchoring in the bone and a head (3) a head receiving part (5) having a first end (5a) and an open second end (5b) with a bounding edge and a hollow interior portion (54) in communication with the open second end for receiving the head (3) therein, the head receiving part (5) being flexible so as to allow clamping of the head a locking ring (6) mounted around the head receiving part, the locking ring having a rod receiving portion (63, 64) wherein the head (3) is pivotable in the head receiving part and can be locked at an angle by compressing the head receiving portion by means of the locking ring (6) a cap (8) configured to cover the rod and to engage the head receiving part, a locking element (9) extending through the cap and configured to engage the rod wherein the cap (8) and the locking ring (6) are rotatable with respect to the head receiving part (5) when the rod is inserted and upon tightening of the locking element the rod and the bone anchoring element are locked with respect to each other.