If you need some time to explore without unnecessary and invasive interruptions, turn on Passive Mode.
Passive Mode is a feature in GTA 5 Online multiplayer that prevents other players from harming you with any weapons. Players can still run you over in cars, crash into you with airplanes, or launch boats at you, but they also won’t know where you are. Passive mode lets you act like a non-playable character.
Likewise, while in passive mode, you will not be able to use any weapons. You also should avoid getting into cars, as other players can still blow up any car or other vehicle you enter.
If you need some time to explore without unnecessary and invasive interruptions, this is your answer. It’s great for learning your way around Los Santos and exploring all of the different things you can do online, and it’s also handy when you’re stuck in an online lobby that is filled with griefers.
When enabled and you are on foot, other players can’t shoot you and you can’t shoot them. It’s wildly unrealistic (or wildly realistic, depending on where you live).
Find Passive Mode in the Interaction Menu
To disable Passive Mode you simply hold your Select (PS3) or Back (Xbox 360) button to open the Interaction Menu, scroll down to Passive Mode and disable it.
Note that there will be a delay before you are able to enable passive mode again. You can also disable passive mode by exiting the GTA Online session.