It is customary [for men] to be toivel in a kosher mikvah on Erev Rosh Hashana, regardless if they are impure or not, in order to spiritually purify themselves in preparation for the holy day. (Rama Siman 581:4)
The accepted custom is to immerse in the mikvah three times to signify the 3 times it says the word “Tahara” (purity) in the pasuk (Yechezkael 36:25): “V’Zarakti Aleichem Mayim Tehorim U’Tehartem MiKol Tumoseichem U’Mikol Giluleichem A’Taher Eschem” (“[Hashem says] I will sprinkle purified water upon you, and purify you from all your impurities; and from all your filthiness I will purify you”) (See Mateh Ephraim Siman 581:53 )
There are other minhagim regarding how many times to immerse; if you don’t have an established personal custom regarding this, do it three times.
The earliest time for going to the Mikvah is an hour before chatzos (Chatzos is approximately 12:37pm this year). (Mishna Berura Siman 581:26)