|MadSci Network: Medicine|
The kidneys serve two major functions: they keep the salt content of the blood constant, and they filter waste out of the bloodstream. So, the main components of urine are (salt) water and waste products. The major waste product from cells in the body is ammonia, and the major waste product from blood is a broken form of heme called bilirubin. In the liver, each of these is converted into a less hazardous form: ammonia is converted to urea, and bilirubin is degraded to urobilins. Salt, water, and urea are all colorless, but urobilins (which come from degraded pigments) are yellow. So, if you drink a lot, your urine will be more dilute and clearer, and if you get dehydrated, your urine will contain less water and be darker yellow.
Try the links in the MadSci Library for more information on Medicine.