GTA Myths Wiki

Space is an unlikely myth in Grand Theft Auto V. While clearly viewable from the ground, it is said that if your plane is fast enough, it can get past the atmosphere before the engine shuts down from the cold temperature and enter space, with multiple planets accessible. This is likely untrue as the fastest story mode vehicle (the P-996 Lazer) shortcircuits if you attempt to breach the invisible wall that marks the limit of how high you can go, and the fact that outside the sky box surrounding the map lies just an black void is pretty clear evidence that the purported space realm does not exist; however it is possible, though again unlikely, that you're instead transported to an alternate, undiscovered location where space exploration is possible. As mentioned before, this other area is likely made up since no models have been found in the game files, meaning the only known way to access space is via mods.

No plane in Grand Theft Auto Online can get past the invisible wall; making it unlikely that this myth exists in Online Mode, either.