HashiCorp · Terraform-Associate
Validates knowledge of infrastructure as code concepts and the ability to use HashiCorp Terraform in production, covering resource lifecycle management, HCL configuration, providers and modules, state management, and collaborative workflows with HCP Terraform.
Practice Questions
628
≈ 11 practice exams
Duration
60 minutes
Passing Score
70%
Difficulty
AssociateLast Updated
Feb 2026
Use this Terraform-Associate practice exam to prepare for HashiCorp Certified: Terraform Associate with realistic questions, detailed explanations, and focused study modes. The practice bank includes 628 questions for HashiCorp Terraform-Associate, so you can review the exam steadily instead of relying on one long cram session.
As you practice, pay extra attention to patterns in your missed answers. Start with short sessions to identify weak areas, then move into timed quizzes once your accuracy is consistent.
The explanations are especially useful when you want to connect exam wording to the responsibilities and scenarios described in the official certification guidance. Use the free preview first, then unlock the full question bank when you are ready to build a complete study routine.
The HashiCorp Certified: Terraform Associate (004) validates foundational knowledge of infrastructure as code (IaC) using HashiCorp Terraform Community Edition and HCP Terraform. The certification demonstrates that a candidate understands core Terraform concepts including the resource lifecycle, HCL configuration syntax, provider and module usage, state management, and collaborative workflows. Version 004 of the exam covers Terraform 1.12 and introduces updated objectives around lifecycle rules such as `depends_on` and `create_before_destroy`, custom configuration validation conditions, ephemeral values and write-only arguments for sensitive data handling, and HCP Terraform workspace and project organization.
This certification is widely recognized across the cloud and DevOps industry as a benchmark for Terraform proficiency. It is delivered online via Certiverse, proctored remotely, and is valid for two years from the date of passing. Recertification is available by passing the same exam or a higher-level Terraform exam within six months of expiration. The credential includes a digital badge issued through Credly, suitable for sharing on LinkedIn, resumes, and professional profiles.
The Terraform Associate is designed for cloud engineers, DevOps engineers, and infrastructure practitioners who work with or are transitioning into infrastructure automation roles. Candidates are expected to have foundational Terraform skills—either through professional production experience or hands-on work in a personal or demo environment. The exam is appropriate for those in roles such as Cloud Infrastructure Engineer, DevOps Engineer, Site Reliability Engineer, or Platform Engineer who use Terraform to provision and manage cloud or on-premises resources.
Candidates should have basic terminal proficiency and a working understanding of on-premises and cloud architecture. The exam is not intended for complete beginners to cloud infrastructure but is well-suited for those who have completed introductory Terraform tutorials and want to formalize their knowledge with a vendor-recognized credential.
HashiCorp does not mandate formal prerequisites for the Terraform Associate exam, but recommends that candidates possess basic terminal skills and a general understanding of on-premises and cloud architecture prior to sitting the exam. Familiarity with at least one major cloud provider (AWS, Azure, or GCP) and its core services is beneficial, though provider-specific knowledge is explicitly not tested on the exam itself.
Professional experience using Terraform in production is recommended but not required—HashiCorp acknowledges that performing the exam objectives in a personal or demo environment may be sufficient preparation. Candidates should be comfortable reading and writing HCL configuration files, running Terraform CLI commands, and understanding concepts such as state, providers, modules, and the plan/apply workflow before attempting the exam.
The Terraform Associate (004) is a 60-minute, online-proctored exam delivered through the Certiverse platform. The exam consists of approximately 57–60 questions in multiple-choice format, including true/false, single-select, and multi-select question types. The exam is available only in English. The registration fee is $70.50 USD plus applicable taxes and fees.
HashiCorp uses a scaled scoring model and does not publicly disclose the exact number of scored versus unscored items. The passing score is broadly understood to require approximately 70% mastery across all domains. Candidates receive a pass/fail result immediately upon completion, with detailed objective-level performance feedback delivered within approximately 48 hours. The resulting credential is valid for two years.
Earning the Terraform Associate credential positions engineers competitively for roles that require infrastructure automation expertise, including Cloud Infrastructure Engineer, DevOps Engineer, Platform Engineer, and Site Reliability Engineer. According to HashiCorp, 88% of exam takers agree that passing a HashiCorp Associate-level exam makes job candidates more desirable to employers. Terraform's dominant position in the IaC market — used by organizations across every major industry vertical — means the certification is recognized by a broad range of employers and is frequently listed as a preferred or required qualification in infrastructure-related job postings.
The Terraform Associate complements cloud provider certifications (AWS, Azure, GCP) by validating multi-cloud, provider-agnostic infrastructure skills that those vendor-specific certs do not cover. It is commonly pursued alongside or after an associate-level cloud certification to build a well-rounded infrastructure credential profile. For engineers looking to advance further, HashiCorp offers the Terraform Authoring and Operations Professional certification as a logical next step, validating advanced production-level Terraform expertise.
5 sample questions with answers and explanations. The full bank has 628 questions, enough for 11 full-length practice exams.
Preview — answers shown1. A Terraform configuration includes a local-exec provisioner that runs a script to register a newly created EC2 instance with an external monitoring system. The team wants the provisioner to execute only when the instance is being destroyed, not during creation. Which configuration accomplishes this requirement? (Select one!)
Explanation
The when argument in a provisioner block accepts two string values: create (default) or destroy. Setting when = "destroy" ensures the provisioner only runs during resource destruction. The syntax requires quotes around the destroy value. The when argument without quotes is invalid syntax. The on_failure argument controls behavior when provisioners fail but does not control timing of execution. There is no separate destroy provisioner block type in Terraform.
2. A configuration uses a dynamic block to generate multiple security group ingress rules based on a variable. The team discovers that Terraform does not support generating certain block types dynamically. Which block type CANNOT be generated using dynamic blocks? (Select one!)
Explanation
Dynamic blocks cannot generate lifecycle or provisioner blocks because these are meta-arguments that control Terraform's behavior rather than provider-managed resource configurations. Lifecycle blocks must be statically defined in the configuration. Ingress blocks within security groups are typical resource-specific nested blocks that can be generated dynamically. Tag blocks and environment variable blocks are also resource-specific configurations that support dynamic generation. The limitation specifically applies to Terraform meta-arguments like lifecycle and provisioners, not to provider-managed resource arguments.
3. An infrastructure engineer configures a database resource with the following lifecycle block. What will happen if the engineer removes the entire resource block from the configuration and runs terraform apply? (Select one!)
Explanation
The prevent_destroy lifecycle argument only blocks destruction when modifying resource arguments that require replacement. When you completely remove a resource block from configuration, Terraform treats this as an intentional deletion and proceeds with destruction. The prevent_destroy setting does not protect against configuration removal. To safely remove resources from management without destroying them, use terraform state rm or the removed block with destroy set to false.
4. A security-conscious organization requires that all Terraform state files stored in Amazon S3 must be encrypted at rest, encrypted in transit, and include automatic state locking to prevent concurrent modifications. The team uses Terraform 1.12 and wants to eliminate dependency on external services for locking. Which backend configuration meets all requirements with minimum infrastructure dependencies? (Select one!)
Explanation
Terraform 1.10 introduced S3 native locking via use_lockfile equals true, which creates dot-tflock files in S3 and eliminates the DynamoDB requirement. Combined with encrypt equals true for at-rest encryption and the default HTTPS endpoint for transit encryption, this configuration meets all requirements with only S3 infrastructure. The DynamoDB approach works but requires provisioning and managing an additional service. Using Consul or etcd for locking introduces unnecessary complexity and additional infrastructure when S3 native locking is available. KMS encryption is more complex than necessary when basic S3 encryption suffices.
5. An operations team uses HCP Terraform Projects to organize workspaces for different applications. What advantage do Projects provide over organizing workspaces individually? (Select one!)
Explanation
HCP Terraform Projects organize workspaces into logical groups with inherited permissions, enabling hierarchical access control. Teams can grant permissions at the project level which automatically applies to all workspaces within that project, simplifying permission management. Projects do not enable state file sharing between workspaces as each workspace maintains independent state. Projects do not merge configurations from different workspaces. Workspace-level variables are still required for workspace-specific configuration.
$17.99
One-time access to this exam