Curcumin is the main ingredient in turmeric, a common Indian spice. Curcumin shows a broad spectrum of effects, including anti-Alzheimer's and antioxidant properties. An interaction between curcumin and lipid membranes has been speculated as the root cause of this activity, and the molecule is often proposed to protect the bilayer. However, the detailed molecular mechanism of this protection is disputed. There is evidence that curcumin either (a) lies flat on the bilayer and provides a "carpet" for protection by forming a steric barrier, or (b) inserts into the membrane and stiffens tails, thereby protecting against peptide insertion. We studied the interaction between curcumin and 1,2-dimyristoyl-sn-glycero-3-phosphocholine (DMPC) bilayers at different concentrations using high-resolution X-ray diffraction and molecular dynamics (MD) computer simulations. We observed curcumin molecules forming a carpet in dehydrated bilayers, whereas in hydrated membranes the curcumin molecules were found to insert into the bilayers. From calculations of the potential of mean force (PMF), we find two minima, a metastable state in the headgroup region, at |z| ≈ 22 Å, and a global minimum in the hydrophobic membrane core, at |z| ≈ 9 Å. The population of the two states depends on membrane hydration. Experiments may thus observe curcumin in a carpet or inserted position, depending on the osmotic pressure conditions created, for instance, by salts, buffer solutions, substrates, or macromolecular solutes. In the carpet model, curcumin dehydrates lipid bilayers and decreases fluidity. When inserted, curcumin leads to a further fluidification of the membranes and an increase in tail fluctuations, contrary to cholesterol's condensing effect.