There is no direct connection from Dubai to Ajman. However, you can take the Metro to Union Square Bus Station then take the bus to Ajman. Alternatively, you can travel from Dubai to Ajman in around 44 min.
How to get from Dubai to Ajman
From Nakheel Metro to Union Square Bus Station then bus to Ajman. 1 h 38 min AED 7. From Dubai taxi to Ajman. 44 min AED 141. From Dubai drive to Ajman. 44 min AED 13. From Dubai Uber to Ajman. 44 min AED 192.