Can be Risky. This is a complicated question to answer as there are many people for whom anal intercourse is a regular and enjoyed sexual activity. But it is medically risky behavior nevertheless, even if condoms are used as a barrier for stds. The anal sphincter muscle is not anatomically designed to comfortably admit external objects and can be injured or become weak and lead to stool incontinence.
With precautions. You can't get pregnant but you can get sexually transmitted infections, including HIV from anal sex without condoms. It's also possible to aggravate hemorrhoids or stretch the sphincter muscle.