We have used the AMR-CESE-MHD model to investigate the influences of the IMF Bz and the upstream solar wind dynamic pressure (Dp) on Earth’s magnetopause and bow shock. Our results present that the earthward displacement of the magnetopause increases with the intensity of the IMF Bz. The increase of the northward IMF Bz also brings the magnetopause closer to the Earth even though with a small distance. Our simulation results show that the subsolar bow shock during the southward IMF is much closer to the Earth than during the northward IMF. As the intensity of IMF Bz increases (also the total field strength), the subsolar bow shock moves sunward as the solar wind magnetosonic Mach number decreases. The sunward movement of the subsolar bow shock during southward IMF are much smaller than that during northward IMF, which indicates that the decrease of solar wind magnetosonic Mach number hardly changes the subsolar bow shock location during southward IMF. Our simulations also show that the effects of upstream solar wind dynamic pressure (Dp) changes on both the subsolar magnetopause and bow shock locations are much more significant than those due to the IMF changes, which is consistent with previous studies. However, in our simulations the earthward displacement of the subsolar magnetopause during high solar wind Dp is greater than that predicted by the empirical models.