---
description: >
  The `packer inspect` command outputs the variables, builders, and provisioners a template uses so you can review the template without reading the HCL.
page_title: packer inspect command reference
---

# `packer inspect` command reference

The `packer inspect` command takes a template and outputs the various
components a template defines. This can help you quickly learn about a template
without having to dive into the HCL itself. The command will tell you things
like what variables a template accepts, the builders it defines, the
provisioners it defines and the order they'll run, and more.

This command is extra useful when used with [machine-readable
output](/packer/docs/commands) enabled. The command outputs the components
in a way that is parseable by machines.

The command doesn't validate the actual configuration of the various components
(that is what the `validate` command is for), but it will validate the syntax
of your template by necessity.

## Example

Given a basic template, here is an example of what the output might look like:

```shell-session
$ packer inspect template.pkr.hcl
> input-variables:

var.aws_access_key: "<sensitive>"
var.aws_secret_key: "<sensitive>"

> local-variables:

> builds:

  > <unnamed build 0>:

    sources:

      amazon-ebs.foo
      amazon-instance.bar
      virtualbox-iso.basic

    provisioners:

      shell

    post-processors:

      <no post-processor>
```
