In a living tree, the live wood contains a certain amount of moisture in its fibres. These fibers are like small tubes packed side by side, shrinking or swelling according to the amount of moisture present. When the tree is felled and cut into timber a great deal of the moisture is set free and evaporates. Once the wood has had time to dry, it will retain its shape as long as it remains so. Let dampness creep in, however, and the fibres will begin to swell, even in a board or plank that has been dry for many years.
Drying a plank properly in the first place is not easy, for one of the difficulties is to get both sides equally dry. If you dampen one side of a thin board and place it near the heat, you will soon find your piece of wood beginning to curl. That is because the fibres in one side are shrinking; and as that side contracts, it draws the other side around with it. The shrinking and swelling take place only across the grain of the wood, leaving its length unaffected by moisture.
Wood warping (Wikipedia)