Is there gravity in space? Absolutely.
Gravity is the attraction between two objects, so anywhere objects exist, gravity exists. That includes the sun and other stars, the planets, objects in distant galaxies, even space dust. They all have gravity. Scientists are continually discovering more about these gravitational connections.