A perianal abscess is a localized collection of pus that forms near the anus due to infection. It typically occurs when a small gland located just inside the anus becomes blocked and infected. Perianal abscesses are a type of anorectal abscess and are relatively common.