It may be due to broken rib or inflammation called as costochondritis
. You should perform an Xray to rule out Rib Fracture
. If there is no rib fracture than there is inflammation for which u should take antiinfammatory drugs such as Brufen
for 05 days.
I hope I am sucessful in solving your query If you have anything more to ask you can ask me
Dr. Azhar Sattar