Kernels are functions used in machine learning algorithms, particularly in support vector machines, to transform data into a higher-dimensional space, enabling the separation of non-linearly separable data. They allow algorithms to fit the maximum-margin hyperplane in a transformed feature space without explicitly computing the coordinates of the data in that space, making complex data patterns more manageable.