Although you might have heard people talk about a gene for red hair, green eyes or other characteristics, it's important to remember that genes code for proteins, not traits. While your genetic makeup does indeed determine physical traits like eye color, hair color and so forth, your genes affect these traits indirectly by way of the proteins created via DNA.
Your DNA carries information in the sequence of base pairs of its nucleotides. These biological molecules, the building blocks of DNA, are often abbreviated with the first letter of their names: adenine (A), thymine (T), guanine (G) and cytosine (C).
The types and sequence of nucleotides in DNA determine the types and sequence of nucleotides in RNA. This in turn determines the types and order of amino acids included in proteins. Specific three-letter groups of RNA nucleotides code for specific amino acids. The combination TTT, for example, codes for the amino acid phenylalanine. Regulatory regions of the gene also contribute to protein synthesis by determining when the gene will be switched on or off.
In active genes, genetic information determines which proteins are synthesized and when synthesis is turned on or off. These proteins fold into complicated three-dimensional structures, somewhat like molecular origami.
Because each amino acid has specific chemical characteristics, the sequence of amino acids determine the structure and shape of a protein. For example, some amino acids attract water, and others are repelled by it. Some amino acids can form weak bonds to each other, but others cannot. Different combinations and sequences of these chemical characteristics determine the unique three-dimensional folded shape of each protein
Structure & Function
The structure of a protein determines its function. Proteins that catalyze (accelerate) chemical reactions, for example, have "pockets," which can bind specific chemicals and make it easier for a particular reaction to occur.
Variations in the DNA code of a gene can change either the structure of a protein or when and where it is produced. If these variations change the protein structure, they could also change its function. For example, a single, specific mutation in hemoglobin -- the oxygen-carrying protein abundant in your red blood cells -- affects oxygen transport and is enough to cause sickle-cell anemia.
Variations in a gene can affect traits in several ways. Variations in proteins involved in growth and development, for example, can give rise to differences in physical features like height. Pigments of skin and hair color are produced by enzymes, proteins that catalyze chemical reactions. Variations in both the structure and quantity of the proteins produced give rise to different amounts of skin and hair pigment and therefore different colors of hair and skin.