There are no boundaries, the game just occurs on a really small planet. Reaching one edge wraps you around to the other.
Trapped inside a fantasy theme park or nature preserve with really tall fences.
The area is surrounded on all sides by unfriendly nations with strict immigration policies (or quarantines). Alternatively, the country the game takes place in is a brutal dictatorship that doesn't let anyone leave, ever.
The player is bound to something in the area. If they stray too far, they die (or black out and wake up back in town).
The area is a wizard's pocket dimension, enclosed by a reality bubble.
The area is surrounded by untamed forest/swamp/desert. The player can leave, but all that's out there is endless boring (or dangerous) terrain.
The area is surrounded by fog. The player can leave, but it's impossible to see anything out there, and there's nothing really to see anyway. (With fog, you can also do the "walk for three miles out but when you turn around somehow you make it back after only ten steps" thing, or even get so lost that you ended up wandering back to where you're supposed to be anyway)
The surrounding land is home to wild and dangerous beasts the player could never hope to defeat. Straying too far into their territory is asking for quick death.
You could also have different obstacles on different sides. The ocean is to the east, a mountain range is to the north, a canyon is to the west, and a wall is to the south.