[ Web Proxy ]
URL:
Viewing: https://developers.cloudflare.com/terraform/tutorial/ [Back]  [Original]

Tutorials Cloudflare Terraform docsSkip to content
SearchCtrlKLog in
  1. Home
  2. /Terraform
  3. /Tutorials

Tutorials

Last updated Apr 21, 2026Copy as MarkdownView as MarkdownAgent setup
Overview1 Initialize Terraform2 Track your history3 Configure HTTPS settings4 Improve performance and reliability5 Add exceptions with page rules6 Revert configuration

Before you begin, install Terraform. Each tutorial builds on the previous, so you should complete the tutorials in the order shown below.

Note

If you are upgrading from v4, review the migration guide for breaking changes.

  • Brief introduction.
  • Introduction of terraform init, plan, apply, and show.
  • Resource covered: cloudflare_dns_record (DNS record).
  • Store Cloudflare configuration in source control.
  • Add page rule.
  • Resource covered: cloudflare_page_rule .
  • Increase security level for a specific URL: /expensive-db-call.
  • Add a redirect (URL forward) with a 301 status code from /old-location.php to /expensive-db-call.
  • Review change history.
  • Roll back changes.
PreviousGet startedNext1 Initialize Terraform

Was this helpful?

YesNo
Edit pageReport issue
[]

Web Proxy Viewer  |  New URL  |  Original Page