Disclosed are compounds of formula (I), and pharmaceutically acceptable salts thereof. The compounds are inhibitors of the complement system. Also provided are pharmaceutical compositions comprising a compound of formula (I), and methods involving use of the compounds and compositions in the treatment and prevention of diseases and conditions characterized by aberrant complement system activity.