The regulation of ion channel activity by specific lipid molecules is widely recognized as an integral component of electrical signalling in cells. In particular, phosphatidylinositol 4,5-bisphosphate (PIP2), a minor yet dynamic phospholipid component of cell membranes, is known to regulate many different ion channels. PIP2 is the primary agonist for classical inward rectifier (Kir2) channels, through which this lipid can regulate a cell's resting membrane potential. However, the molecular mechanism by which PIP2 exerts its action is unknown. Here we present the X-ray crystal structure of a Kir2.2 channel in complex with a short-chain (dioctanoyl) derivative of PIP2. We found that PIP2 binds at an interface between the transmembrane domain (TMD) and the cytoplasmic domain (CTD). The PIP2-binding site consists of a conserved non-specific phospholipid-binding region in the TMD and a specific phosphatidylinositol-binding region in the CTD. On PIP2 binding, a flexible expansion linker contracts to a compact helical structure, the CTD translates 6Å and becomes tethered to the TMD and the inner helix gate begins to open. In contrast, the small anionic lipid dioctanoyl glycerol pyrophosphatidic acid (PPA) also binds to the non-specific TMD region, but not to the specific phosphatidylinositol region, and thus fails to engage the CTD or open the channel. Our results show how PIP2 can control the resting membrane potential through a specific ion-channel-receptor-ligand interaction that brings about a large conformational change, analogous to neurotransmitter activation of ion channels at synapses.