Pain in the anus is generally seen when one is suffering from anal fissures. an anal fissure is a tear or an ulcer in the lining of anal canal
, just inside the anal orifice.
Prolapsed, thrombosed piles also give rise to pain in anal region while passing stools.
I advise you to consult a surgeon who can inspect your anal canal and make the diagnosis.
Till you consult him,make sure to keep your stool soft and avoid constipation
You may use XYLOCAINE
JELLY locally before going for bowel motion.