All Tools View Categories About Contact Privacy

Terraform Import Command Builder

Assemble a terraform import command for an existing resource.

Runs entirely in your browser - nothing is uploaded and no Terraform connection is made.
Your terraform import command will appear here.

About Terraform Import Command Builder

The Terraform Import Command Builder assembles a correct terraform import command. Provide the resource type, name and the existing cloud ID; the tool builds the type.name address and appends the ID.

Validation ensures the required fields are present and the type has no invalid characters. Everything runs locally and nothing is uploaded.

Features

  • Address building - type + name become type.name.
  • Optional flags - -provider, -config, -var-file, -var, -state-out.
  • Validation - required fields and address characters checked.
  • Copy / Download / Print - get the command wherever you need it.

How to Use

  1. Enter type, name and ID.
  2. Add optional flags if needed.
  3. Build the command and export it.

Examples

Example 1: terraform import aws_instance.foo i-1234567890abcdef0.

Example 2 with provider: terraform import -provider=aws.eu-west aws_instance.foo i-abc.

Benefits

  • Correct syntax - address assembled automatically.
  • Validated - required fields enforced.
  • Private - everything runs in the browser.
  • Portable - copy, download or print the command.

Frequently Asked Questions

What does terraform import do?
terraform import attaches an existing real-world resource to a Terraform resource address so it is managed by your configuration.
What inputs are required?
You need the resource type, the resource name and the cloud ID of the object to import. The address becomes type.name.
What optional flags are supported?
-provider, -config, -var-file, -var and -state-out.
Does this connect to the cloud?
No. The command is assembled in your browser and nothing is uploaded.
Can I download it?
Yes. Copy the command, download it as a shell snippet, or print it.