Maybe this belongs on physics.stackexchange.com.
Yes, a properly functioning accelerometer that is stationary relative to the surface of the Earth will read the acceleration due to gravity. If it's a very good accelerometer, you could also see the factor of a few hundred smaller decrement in that acceleration due to the centripetal acceleration from the rotation of the Earth. If it's a really really good accelerometer, you could also see the tidal force due to the Moon, about seven orders of magnitude down from the surface acceleration.
An accelerometer in the spacecraft, at least if it's at or close enough to the center of gravity of the spacecraft, will read exactly zero if the spacecraft is in free fall. I.e., not firing any thrusters. The accelerometer is useful during rocket firings to get a measure of the actual acceleration during the burn. (This is usually improved upon later with navigational tracking.) But useless in free fall.
You will not detect the gravity of nearby objects with an accelerometer. It will read zero the entire time you are moving through the vacuum. With one caveat, which is again if it's a really really good accelerometer, and you swing by very close to a large body, and you put the accelerometer as far from the center of gravity of the spacecraft as you can, then you might be able to detect the tidal force from the body for a short time. That force drops off as the cube of distance as opposed to the square, so it would be very difficult to detect. In any case, you would not be able to navigate with that, since if you're already that close to the body then it's too late to correct your trajectory.
In general, you cannot navigate a spacecraft, e.g. correcting errors in your trajectory, without, effectively, looking out the window. Either with optical or radio tracking data of some kind.