Skip to content
| Marketplace
Sign in
Visual Studio Code>Programming Languages>HCL SchemaNew to Visual Studio Code? Get it now.
HCL Schema

HCL Schema

Avestura Technologies

|
190 installs
| (0) | Free
Validation, completion and hover for HCL files described by .schema.hcl
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

HCL Schema for VS Code

Validation, completion and hover for HCL files described by a *.schema.hcl schema.

Documentation: https://avestura.github.io/hcl-schema/

What it does

Add a __schema attribute to an HCL file:

__schema = "./service.schema.hcl"

name = "checkout"

listener "https" {
  port = 443
}

and the extension gives you, against that schema:

  • Diagnostics as you type, on the unsaved buffer
  • Completion of declared attributes and blocks, and of an attribute's permitted values
  • Hover documentation written once in the schema's description
  • Go to definition from a use to its declaration in the schema
  • A document outline

Screenshot

Settings

Setting Default Meaning
hclSchema.cliPath "" Path to the hclschema binary. Empty uses the bundled one.
hclSchema.strict false Apply draft 2026-09 rules to schemas that pin an older draft
hclSchema.offline false Never fetch remote schemas; use the cache only
hclSchema.cacheDir "" Where cached remote schemas live

Commands

  • HCL Schema: Validate active file
  • HCL Schema: Restart language server
  • HCL Schema: Show output

Requirements

None. The binary for your platform ships with the extension. The HashiCorp HCL extension is installed alongside it for syntax highlighting.

License

MIT.

  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
  • Your Privacy Choices
  • Consumer Health Privacy
© 2026 Microsoft