# Terraform state file 🔐

### Description

Terraform stores the information of the execution (apply or destroy) in a special file called `tfstate`. This is file is critical for future provisioning of the infrastructure as it is the absolute reference of which resource has been deployed or not.

🛡️ Refer to the [remote backend page](https://docs.brainboard.co/data/data-structure/cloud-architecture/remote-backend) for detailed information on how to configure and manage your state files in Brainboard.

### How it works

🎒 Refer to our [training session](https://youtu.be/Q3RYArLenYg) if you want to understand how Terraform works and how the tfstate is used.

![How Terraform works](https://2733077811-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F7YhVIZuz5Brv8kisTlFL%2Fuploads%2Fgit-blob-8cf3a1e13f5f31921c9adb6dc9e56a71d8583901%2Fhow-terraform-works.png?alt=media)


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.brainboard.co/cloud-architectures/terraform-state.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
