The perspective() CSS function of the transform property sets the distance between the user and the z=0 plane. It helps us to give a 3D effect as it can make how closer or further the viewer can see the 2D or 3D elements. The perspective() value cannot be negative because the perspective(0) is the highest value where z=0 plane. If we increase the perspective() value, the distance between the user and the z=0 plane will also increase.