Graph kernels are a class of functions used to measure the similarity between graphs, enabling the application of kernel-based machine learning methods to graph-structured data. They work by embedding graphs into a high-dimensional space where linear algorithms can be applied, facilitating tasks like classification, clustering, and regression on graph data.