Matrix factorization is a technique used in collaborative filtering recommender systems. It involves representing both users and items as vectors in a low-dimensional latent factor space, and predicting user ratings of items based on the dot product of their vectors. The model is trained using stochastic gradient descent to minimize the regularized squared error between actual and predicted ratings. Matrix factorization is commonly used for tasks like collaborative filtering, linear regression, PCA, and clustering.