how to delete a image docker code example Example 1: remove docker images docker system prune -a Example 2: how to remove docker images docker image rm