Piles or hemorrhoids is a painful condition of inflammation and swelling that affects the veins around the anus or rectum. Although the pain can often be unbearable, in most cases the condition itself is not threatening.