A group $\Gamma$ is defined to be {\em{cofinitely Hopfian}} if every homomorphism $\Gamma\to\Gamma$ whose image is of finite index is an automorphism. Geometrically significant groups enjoying this property include certain relatively hyperbolic groups and many lattices. A knot group is cofinitely Hopfian if and only if the knot is not a torus knot. A free-by-cyclic group is cofinitely Hopfian if and only if it has trivial centre. Applications to the theory of open mappings between manifolds are presented.