As far as I understand, gravity wells prevent hyperspace travel.
What's the in-universe explanation for how Han was able to hyperspace travel through the First Order's shields, and even land successfully, in The Force Awakens?
Science Fiction & Fantasy Stack Exchange is a question and answer site for science fiction and fantasy enthusiasts. It only takes a minute to sign up.Sign up to join this community
Han Solo explains how the Millennium Falcon (and any ship travelling at lightspeed) can get through the First Orders defensive shielding (As Admiral Ackbar calls it)
He refers to it as a "fractional refresh rate" which means that rather than being a continuous wall of energy, it is produced in pulses (from the shield generator) and every X amount of time, there is a small window of opportunity to pass through it, but of course, you have to be going really fast meaning lightspeed or more.
I'd like to add, that the duplicate answer marked in the question does not correctly answer this question and in fact just speculates. There is however, correct answers here:
As I said, the shield fluctuates/flickers/pulsates meaning for a fraction of a second, they are down, and so a ship can pass through.
As far as I know, Star Wars hyperdrive can take a ship anywhere in realspace via hyperspace, as long as the calculations are done correctly. Gravity wells and shielding, at least in current canon, aren't known to affect the hyperspace dimension, as far as actual travel goes, because hyperspace is an entirely different dimension from realspace. The reason we usually don't see pilots doing this kind of maneuver is because without the proper calculations, it's extremely dangerous due to the massive scale and speed involved with this kind of travel, so they take established hyperspace routes. Han was stupidly gambling his life, along with the entire Resistance, by trying to go to lightspeed without the proper calculations, but it's completely possible to do with enough luck.