Density peaks clustering (DPC) algorithm has been widely applied in many fields due to its innovation and efficiency. However, the original DPC algorithm and many of its variants choose Euclidean distance as local density and relative distance estimations, which affects the clustering performance on some specific shaped datasets, such as manifold datasets. To address the above-mentioned issue, we propose a density peak clustering algorithm with connected local density and punished relative distance (DPC-CLD-PRD). Specifically, the proposed approach computes the distance matrix between data pairs using the flexible connectivity distance metric. Then, it calculates the connected local density of each data point via combining the flexible connectivity distance measure and k-nearest neighbor method. Finally, the punished relative distance of each data point is obtained by introducing a connectivity estimation strategy into the distance optimization process. Experiments on synthetic, real-world, and image datasets have demonstrated the effectiveness of the algorithm in this paper.