State Rep. Ralph Arza had been urged to step down by fellow House Republicans and by Gov. Jeb Bush.
In a news conference Wednesday, Arza apologized for his actions and said he didn't want to distract from the work of the Republican-led Legislature.
"I do not want to be the story," he said.
Arza had acknowledged leaving the message on fellow Republican Rep. Gus Barreiro's voice mail last month, but said he was drunk.
He said he had learned that Barreiro had filed a complaint alleging he had earlier used a racial epithet when referring to Miami-Dade County school superintendent Rudy Crew, who is black. He used the same epithet in his phone message to Barreiro, who is Hispanic.
Arza resigned about an hour before a special House panel was set to begin hearings on whether to expel him.
"It's not really a happy day for anybody, I don't think," said Barreiro, of Miami Beach. "I think he made the right decision, the right decision, not only for himself, but I thought he looked at the bigger picture, which is the institution he represents. I wish him the best."
The Republican Party gets to choose a replacement for Arza in the general election, less than a week away, but Arza's name will still be on the ballot. The situation would be similar to what has happened in former U.S. Rep. Mark Foley's district, when the GOP replaced him with Joe Negron.
"Any vote for Arza would be contributed to the new nominee," said state Division of Elections spokeswoman Jenny Nash.