Build AWS Config custom Lambda rules with remediation actions.
Last verified: May 2026
Build AWS Config custom rule configs with Lambda evaluation, scope, and auto-remediation.
Required Fields
ConfigRuleNameSource.OwnerSource.SourceIdentifierSource.SourceDetailsOutput will appear here...Your team's compliance officer mandates: every production resource must have a `cost-center` tag matching the central allow-list. No managed rule covers this exact requirement. The builder helps generate a custom rule: change-triggered on EC2/RDS/S3/Lambda resources, Lambda function checks the resource's tags against an allow-list stored in SSM Parameter Store, returns NON_COMPLIANT if missing or wrong. Auto-remediation: SSM Automation document that emails the resource owner. Within a week of deploy, 30 non-compliant resources are surfaced and tagged correctly.
AWS Config tracks resource configurations and evaluates them against rules for compliance. While AWS provides over 300 managed rules, custom rules let you implement organization-specific compliance checks using Lambda functions. A custom rule triggers on configuration changes or on a schedule, invokes your Lambda function with the configuration item, and expects a compliance evaluation response. The Config Custom Rule Builder helps you define the rule metadata, trigger types, input parameters, and remediation action configurations so you can deploy custom compliance checks consistently.
The builder generates Config custom rule definitions: rule name, description, source (Lambda function ARN), trigger (configuration changes with resource type filters, OR periodic with interval), input parameters (passed to Lambda as the rule's evaluation context), maximum execution frequency, and optional remediation configuration (SSM Automation document + parameters). Output is generated as aws configservice put-config-rule commands and Terraform aws_config_config_rule resources.
Always exhaust managed Config rules before writing custom ones. AWS has 300+ managed rules covering most compliance scenarios. Custom rules add maintenance burden (Lambda code, deployment, monitoring). Search the managed catalog first using the Config console's rule library.
Periodic rules consume invocations every 1-24 hours regardless of resource count. For organizations with 100+ accounts and 50+ rules, periodic invocations add up. Prefer change-triggered rules where possible — they only run when relevant resources actually change.
Auto-remediation should only be enabled for low-blast-radius actions (removing public access from S3, encrypting unencrypted EBS). Never auto-remediate things like 'fix VPC security group' — automatic changes to networking can cause production incidents. Use manual approval mode for those.
Was this tool helpful?
Disclaimer: This tool runs entirely in your browser. No data is sent to our servers. Always verify outputs before using them in production. AWS, Azure, and GCP are trademarks of their respective owners.