Both terms are used to denote isolated user environments running on a physical hardware resource. Containers are mostly associated with OS-level virtualization, which means they use the host's kernel. By contrast, a VM only uses the physical machine's hardware and can run on an operating system different from the host's.