Early experiments by Stanley Miller showed that organic molecules like amino acids could form from simple molecules like methane, ammonia and hydrogen with energy from heat and electricity. More recent experiments have found that amino acids and other organic molecules form easily under these conditions, suggesting this could have been how the first organic molecules formed on early Earth before the emergence of life. Proteins are made of amino acids linked together in chains that then fold into complex 3D shapes determined by interactions between their variable side chains. This folding allows proteins to perform a huge variety of functions in living cells and organisms.