So you tell the players OOCly (out of character-ly) not to go to a certain part of the world because they will die. You give them warning ICly (in character-ly) to stay clear. And what do they do?
I run an open world. It's very much like an MMORPG in it's setup. For example. The characters start out in a little town called Mill's Crossing. Near to their homes, they have rats and bats to fight - 'rats and bats' are metaphors for low level monsters. They farther out they go, the more complex and dangerous the world becomes. This also applies to 'straying off the path'. For example; Well traveled roads are generally safer than pathways or the road less traveled.
So, if a player character ventures too far out, or passes beyond common areas for his level, then the danger level rises. But, they're fully permitted to do this. They're free to step in front of a rampaging chariot or jump off a cliff. I don't limit their choices, but I do warn them.
But what do they always do?
"Hey everybody, this sign says, "Danger, do not enter, Plane of Fire beyond door." Plane of fire? Sweet, let's go!" - instant death follows.