The question is as in the title, i.e.

Does $G\times H \cong G\times K$ imply $H\cong K$, where $G,H,K$ are finite groups?

We can show that

(1) the abelianizations of $H$ and $K$ are isomorphic

(2) $H/M_S(H)\cong K/M_S(K)$, where $S$ is a non-abelian finite simple group and for a group $G$, $M_S(G)$ is the intersection of all normal subgroups $U$ with $G/U\cong S$; so $G/M_S(G)$ is the maximal quotient of the form $S\times \cdots \times S$.

2more comments