After hearing a fan sitting near the court behind the Heat's bench mention his mother's name, James walked toward the scorer's table and addressed the male fan.
"I don't care what you say to me. I don't give a [expletive] what you say," James said to the fan. "But don't be disrespectful."
The exchange came during a break in action with 1.7 seconds left in the first quarter and was picked up by television microphones.
James responded to the fan, who shouted the comments within earshot of James' two young sons who sat courtside near the Heat's bench.
The fan, who declined to give his name to ESPN.com, said he was offended by James' cursing. He was also told by security to refrain from heckling the rest of the game or he would be escorted out.
Michael Wallace covers the NBA for ESPN.com.