*Floyd Mayweather Jr. was caught on tape cursing out a security guard inside his Las Vegas community earlier this month — all because the guy didn’t recognize him.

TMZ has obtained footage of the incident, which took place Sunday Dec. 19 around 4 a.m. — when Floyd drove up to the main gate and the security guard asked him for ID.

That’s when the boxer started screaming, “Let me in my mother f**king house!!! You know who I am man … let me in my house!!!”

Mayweather continues, “Stop giving me a hard time … you don’t give Maloof a hard time … you don’t ask him for ID when he comes.”

During his tantrum — Floyd also references a prior incident with security in which the boxer was accused of battering one of the guards during a parking dispute … saying, “I had a problem here before when the security lied and said I touched him and I didn’t!”

Floyd eventually got out of the car, went into the guard shack and opened the gate himself.

The tape has been turned over to police and the footage may be used in the battery case to show Floyd has a dubious history with guards.

Click here to watch the footage.