A neurotransmitter—a type of chemical used by the nervous system to carry signals from one place to another—called serotonin is synthesized out of a nutrient called tryptophan, which is part of proteins in the brain and in the intestines. Most of it, as much as 90 percent, is in the gut, where it is a part of the digestive process. Serotonin regulates appetite and is responsible for the body's response to poisons and other things that are not fit to eat.
The rest, the serotonin produced and used in the brain, is separate. The blood-brain barrier keeps serotonin in the brain from going to the gut, and vice-versa; the level in one is not effected by the level in the other. Serotonin in the brain is related to mood balance and social behavior. The two functions are not unrelated; among humans, social status is a part of how well one eats. Even in civilization, social occasions often involve food. Culture recognizes the link between interaction and appetite.
Serotonin is also associated with clinical depression. Depression often includes poor motivation and low libido and sexual response, and depressed people have low levels of serotonin in the brain, where it regulates those things. It is not clear whether low serotonin causes depression or depression reduces serotonin levels, but it seems that the low serotonin in turn affects libido and motivation.
That's why depressive patients are advised to eat healthy and get exercise and sunlight, all of which boost serotonin production. It's also why treatment for depression includes a class of medications called selective serotonin reuptake inhibitors. These SSRIs prevent serotonin produced in the brain from being reabsorbed after it is used. With more serotonin around, these symptoms often diminish.
However, an excess of serotonin can also cause problems, specifically, a condition called serotonin syndrome. This condition, which is almost always a result of SSRIs or other medications that cause serotonin to accumulate, can result in nausea or diarrhea as well as restlessness, confusion, twitching, perspiration, shivering, and goose bumps. In severe cases it can cause fever, irregular heartbeat, and seizures. The symptoms usually go away when the medication is stopped or adjusted, but can be fatal if ignored.