Fentanyl, properly dosed, is actually quite a bit safer than other opiates.
However the amount of fentanyl that makes up an appropriate dose is very much smaller than other opiates. Other opiates in their pure form are more human scale amounts instead of “milligrams is a fatal dose”.
Why fentanyl is dangerous is because drug dealers are poorly preparing counterfeit drugs as a result of its high potency. Poorly mixed with fillers, one pill does nothing, the next one kills you.