The sheriff's office says the boat was 41 feet long and two passengers were on board before an electrical fire broke out on board.
The sheriff's office said the two men were traveling from Fort Pierce to Lake Worth when the fire started.
The men abandoned ship and were found floating on a raft by a good samaritan, just 10 minutes after hopping of their boat.
The men were taken to Sandsprit Park and didn't suffer any injuries.
Martin County Sheriff's Office said the boat sank offshore.