CloudFormation is a tool for automating the creation, updating, and management of your entire resource stack. It provides a way to turn your infrastructure into code, in the form of a YAML file, which can be version controlled alongside your software.