Self-assembly refers to the ability and tendency of various soft materials to adopt an ordered structure due to the laws of thermodynamics (2). The parameters of most systems consisting of soft matter move toward thermal equilibrium and minimal free energy over time, but the resulting substance often is not homogeneous or uniform. On the contrary, for some materials thermodynamic equilibration leads to the formation of structure at one or more scales. When self-assembly occurs over multiple length scales, the structure can be described as hierarchical. Molecules may assemble to form supramolecular structures, like micelles, and in turn these supramolecular structures may assemble into a crystal or other ordered structure on their own. The Second Law of Thermodynamics can thus generate structures of great complexity.
For a process to be considered an example of self-assembly, it must first of all result in a structure or pattern with some sort of recognizable or quantifiable order at a level greater than that of its original inputs. The input components themselves must be larger than atoms or small molecules and in fact may span multiple length scales to the mesoscopic regime. Finally, weak interactions such as Van der Waals or capillary action are generally the forces responsible for self-assembly, rather than strong chemical interactions such as covalent or ionic bonding. Some definitions further restrict self-assembly to processes which are also reversible.
Self-assembly is an important phenomenon in disciplines ranging from materials science to biophysics. The folding of nucleic acids and proteins involves self-assembly, as does the formation of various colloidal and photonic crystals, polymer structures, lipid bilayers, and some monolayers.
1. IBM Almaden Research Center. "Modeling Self-Assembly". (2009) 
2. Jones, Richard. Soft Condensed Matter. (2002)