Cylindrical/ring-shaped permanent magnets with diametrical magnetization can be found in many applications, ranging from electrical motors to position sensory systems. In order to correctly calculate the magnetic field generated by a permanent magnet of this kind with low computational cost, several studies have been reported in literature providing analytical expressions. However, these analytical expressions are either limited for an infinite cylinder or for computing the magnetic field only on the central axis of a finite cylinder. The others are derived to calculate the magnetic field at any point in three-dimensional (3D) space but only with low accuracy. This paper presents an exact analytical model of the magnetic field, generated by a diametrically magnetized cylindrical/ring-shaped permanent magnet with a limited length, which can be used to calculate the magnetic field of any point in 3D space fast and with very high accuracy. The expressions were analytically derived, based on geometrical analysis without calculating the magnetic scalar potential. Also, there is no approximation in the derivation steps that yields the exact analytical model. Three components of the magnetic field are analytically represented using complete and incomplete elliptical integrals, which are robust and have low computational cost. The accuracy of the developed analytical model was validated using Finite Element Analysis and compared against existing models.