Sample complexity refers to the number of training samples needed for a learning algorithm to achieve a certain level of performance or accuracy. It is crucial in determining the feasibility and efficiency of machine learning models, especially in scenarios where data collection is costly or limited.