Daly City resident Richard Willis was arrested for the attack, which was reported at about 4:30 p.m. Sunday in the carport of an apartment complex in the 300 block of Esplanade Avenue, Pacifica police Capt. Daniel Steidle said.
The 25-year-old victim was struck multiple times with the baseball bat, including at least once in the head, Steidle said.
Investigators determined the attack stemmed from an ongoing dispute between Willis and the victim, Steidle said.
At about 6:30 a.m. today, Willis was arrested at his workplace in Burlingame and was booked into San Mateo County Jail on suspicion of attempted homicide, assault with a deadly weapon and making terrorist threats, police said.
He is being held in lieu of $750,000 bail, according to police.