Fentanyl claims dozens of lives a month where I live. I assume most of them were just trying to get high, not die. So I'm sure it can work, but how certain it is is another matter, since street drugs are not reliably pure. They can be stronger than expected, and kill you, or cut with weaker stuff or just different stuff and fuck you up other ways.
There are also risks to obtaining it, of course, but I don't know a lot about that.