Tested tool guide
Tested browser tools
Checked August 16, 2026
What Terraform / HCL Formatter does, with a checked example
Paste an HCL or Terraform configuration and this tool returns the same file rewritten in canonical style: two-space indentation, aligned equals signs, and braces positioned per the canonical format defined in the HCL specification. The pass is purely about layout - comments, string values, and the order of arguments and blocks survive unchanged; input that does not parse is rejected outright; and the text never leaves the browser. The thing users most often misread: clean formatting is not validation. The output can look flawless and still reference undefined variables or misspelled argument names.
Worked example
A concrete input and expected output from the current implementation.
Input
resource "aws_instance" "web" {
ami = "ami-0c55b159cbfafe1f0"
instance_type = var.instance_type
tags = {
Name = "web"
Env = "prod"
}
}
->
Expected output
resource "aws_instance" "web" {
ami = "ami-0c55b159cbfafe1f0"
instance_type = var.instance_type
tags = {
Name = "web"
Env = "prod"
}
}
The body lines are indented two spaces, and the equals signs of ami, instance_type, and tags all align to the longest key, instance_type. Inside the object, Name and Env align to Name, and each closing brace drops to the indentation of the construct it closes.