One of the main tasks in space physics is to explain the various ways the Sun/solar wind, magnetosphere, ionosphere, and even upper atmosphere (thermosphere) are coupled to each other. In addition to the scientific value, this question has also practical value, see space weather and space climate.
Solar wind - magnetosphere
The coupling between the solar wind and the magnetosphere is probably realized via a magnetic reconnection process between the (solar wind carried) IMF Bz component and the geomagnetic field. It creates the large scale convection electric field responsible for geomagnetic activity.
Magnetosphere - ionosphere
Ionosphere and magnetosphere are closely linked together via magnetic field lines. Magnetospheric electric fields map down to the ionosphere, creating, e.g., plasma convection, frictional heating and plasma instabilities (see radar aurora). Auroral particle precipitation ionizes the high latitude atmosphere also during nighttime, and heat can be conducted from the magnetosphere down to the ionosphere (see low-latitude aurorae).
On the other hand, some of the cold ionospheric electrons and ions evaporate into the plasmasphere, plasma sheet and tail lobes. The changed magnetospheric ion composition (especially increased O+) can have large effects on some important magnetospheric processes (see Source of magnetospheric plasma).
Ionosphere - thermosphere
Collisions between the convecting ionospheric plasma and the neutral atmosphere leads to generation of neutral winds and Joule heating of the neutral gas. Neutral gas can be further heated by plasma instabilities that arise due to the ionospheric currents. Furthermore, the role of the newly discovered high-altitude atmospheric flashes in the ionospheric physics is still unknown.