Proteins are composed of amino acids which have multiple functions, primarily helping to transport important substances into the blood and then in turn, aiding growth and repair of human tissue, this (for muscles) is known as muscle protein synthesis (MPS).
There are 20 different amino acids, 8 of which are essential and cannot be made by the body and therefore need to be consumed via diet. The other 12 are non-essential in consumption and can be made by the body.
Protein foods that contain all essential amino acids are called 'complete proteins' or 'ideal proteins'. Complete proteins include most meat and dairy products, quinoa, hemp seeds, chia seeds and soy.
Many plant-based proteins are not complete proteins. These include beans, grains and legumes. However, incomplete proteins can be combined to create complete proteins.
How much Protein?
A protein amount of 1.6g-2g per kg of bodyweight is optimal. Anymore than this will not increase its effectiveness.
Should you currently be training to increase your muscle mass, you should be targeting 0.4g per kg of bodyweight per meal over 4 or more meals per day. For weight loss, protein consumption is even more important, however the timing and frequency is not as important.