It seems you are talking about Kernels in the context of machine learning. In which case the difference between the Kernel and the Kernel \ Gram matrix can be understood via the following expression of Mercer's theorem:
Mercer's theorem in the context of machine learning
Let $X = \{x^{(1)}, ... , x^{(m)} \}$ be a data set of $m$ points, each of which are $n$ dimensional vectors, i.e. $x^{(i)} \in \mathbb{R}^n$ then the function $K$ which maps
$$ K(x^{(i)},x^{(j)}) : \mathbb{R}^n \times \mathbb{R}^n \rightarrow \mathbb{R}$$
is a valid Kernel if and only if the matrix $G$, called the Kernel matrix, or Gram matrix is symmetric, positive semi-definite.
The matrix $G$ is an $m \times m$ matrix where each entry is the kernel of the corresponding data points.
$$G_{i,j} = K(x^{(i)}, x^{(j)})$$
Furthermore, note that
A function $K(x,z)$ is a valid kernel if it corresponds to an inner product in some (perhaps infinite dimensional) feature space.
Hence:
For the linear kernel, the Gram matrix is simply the inner product $ G_{i,j} = x^{(i) \ T} x^{(j)}$. For other kernels, it is the inner product in a feature space with feature map $\phi$: i.e. $ G_{i,j} = \phi(x^{(i)})^T \ \phi(x^{(j)})$
Sources
Page 18 - https://see.stanford.edu/materials/aimlcs229/cs229-notes3.pdf
Page 45
page 52 - https://people.eecs.berkeley.edu/~jordan/kernels/0521813972c03_p47-84.pdf