The basicity of amines depend upon its ability to donate the lone pair of electrons on nitrogen.
Order of basicity of amines in aqueous solution is,
$$NH_3<Primary \ amines(RNH_2)<Tertiary \ amines(R_3N)<Secondary \ amines(R_2NH)$$
This is due to the combined effect of +I effect of alkyl group, steric hindrance caused by alkyl groups and solvation of amines through H-bonding.
The power to donate lone pair of electrons increases as the number of alkyl groups increase. Therefore, making $$R_3N$$ most basic, followed by $$R_2NH$$ and $$RNH_2$$.
But as the number of alkyl groups increase, the steric hindrance caused by them also increases. Thus, decreasing the electron donating power of amines. Hence, making $$RNH_2$$ most basic followed by $$R_2NH$$ and $$R_3N$$.
Solvation is the formation of protonated amines when they are dissolved in water. As the number of H-atoms on nitrogen increases the possibility of H-bonding also increases, providing greater stability to the amine. Thus, primary amine $$(RNH_2)$$ is more stable than secondary amine $$(R_2NH)$$, which is more stable than tertiary amine $$(R_3N)$$.
The combined effect of these three factors give the observed order of basicity of amines in aqueous solution.