Terraform "Unsupported argument" in CI
A block contains an argument the schema does not recognize. The argument is misspelled, belongs to a nested block, or was renamed/removed in a newer provider or module version.
What this error means
validate/plan fails with "Unsupported argument", saying an argument "is not expected here". It frequently follows a provider or module upgrade that renamed, moved, or dropped the argument.
Error: Unsupported argument
on main.tf line 14, in resource "aws_instance" "web":
14: name = "web-server"
An argument named "name" is not expected here.Common causes
Argument renamed or removed by an upgrade
A newer provider or module version renamed (e.g. name → tags.Name) or removed the argument, so the old name is no longer accepted.
Wrong place or typo
A typo, or putting a nested-block argument at the top level (or vice versa), makes the schema reject it as unexpected.
How to fix it
Use the argument the current schema expects
Check the provider/module docs for the version you run and use the correct argument name and placement.
resource "aws_instance" "web" {
ami = var.ami
instance_type = "t3.micro"
tags = { Name = "web-server" } # not a top-level "name"
}Reconcile after upgrades
- Read the provider/module changelog for renamed or removed arguments.
- Update the config to the new argument names and nesting.
- Run
terraform validateto confirm no other arguments are unsupported.
How to prevent it
- Review provider/module upgrade notes for argument changes.
- Pin provider and module versions so schemas don’t shift unexpectedly.
- Run
terraform validatein CI to catch unsupported arguments before apply.