There is gravity everywhere. It doesn't work so that enough far away from the Earth, there won't be gravity any more.
In Low Earth Orbit (i.e. things orbiting Earth), they are in nearly the same gravitational field as we are. For example, the ISS orbits roughly 400 km above the Earth, which is only 400/6378 $\sim$ 6.3 % farther from the center of the Earth than the surface. Since gravity scales as $1/r^2$ that means at that altitude, gravity is still about 88% as strong as on the surface.
The people of the ISS are in weightlessness because they are also flying 7.8km/s speed (around 28000 km/h). This results in a centripetal force which compensates the gravity of the Earth. This is why the ISS doesn't fall down.
Farther away from the Earth, the gravity of the Moon, or other planets, or the Sun would affect more. These are typically far lesser effects as we have on the Earth, but they still exist. Planning the trajectories of space probes, all of them should be calculated.
Thus, if you simply fly upward and shut down the engines, you will fall down. If you fly faster than 11.2km/s, then your spaceship will leave Earth and never come back. If you want to orbit Earth, you have to leave the atmosphere (around 100km height) and accelerate to the speed of at least 7.8km/s sideways around the Earth (because there is a little air even there, 300km is more practical).