Investigators said several people broke into the home and were trying to steal electronics.
The thieves forced the 11-year-old, who was home alone, into a bedroom closet at gunpoint.
Deputies say the boy, who is a star baseball player on several area teams, left the closet and found a machete in the home.
He went into his living room, according to investigators, swung the machete and hit the intruder in the back of the head.
The man retaliated by kicking the boy in the stomach. The boy got up, swung the machete and missed. The intruder then kicked the child in the side of the head, turned to grab several items, including a PlayStation and a television but realized he was bleeding significantly from the machete strike.