It follows from work of Perelman that any finite-time singularity of the Ricci flow on a compact $3$-manifold is modeled on an ancient $\varkappa$-solution.
We prove that every non-compact ancient $\varkappa$-solution in dimension $3$ is isometric to a family of shrinking cylinders (or a quotient thereof), or to the Bryant soliton. This confirms a conjecture of Perelman.