anomalyco/sst · error · VisibleError

Region ${region} is not supported by this component. Please

Error message

Region ${region} is not supported by this component. Please select a different AWS region.

What it means

Beyond being a valid AWS region string, SSR site regional deployment only supports a specific allow-list of regions (us/eu/ap/SA/AF/ME/il/ca central+standard regions listed in the source). If any entry in `regions` is a valid AWS region but outside that list, SST throws this error naming the offending region.

Source

Thrown at platform/src/components/aws/ssr-site.ts:1241

        if (regions.length === 0)
          throw new VisibleError(
            "No deployment regions specified. Please specify at least one region in the 'regions' property.",
          );

        return regions.map((region) => {
          if (
            [
              "ap-south-2",
              "ap-southeast-4",
              "ap-southeast-5",
              "ca-west-1",
              "eu-south-2",
              "eu-central-2",
              "il-central-1",
              "me-central-1",
            ].includes(region)
          )
            throw new VisibleError(
              `Region ${region} is not supported by this component. Please select a different AWS region.`,
            );

          if (!Object.values(Region).includes(region as Region))
            throw new VisibleError(
              `Invalid AWS region: "${region}". Please specify a valid AWS region.`,
            );
          return region as Region;
        });
      });
    }

    function normalizeRoute() {
      const route = normalizeRouteArgs(args.router, args.route);

      if (route) {
        if (args.domain)
          throw new VisibleError(

View on GitHub (pinned to a0bd20f762)

Solutions

  1. Replace the unsupported region with one from SST's supported list (e.g. us-east-1, eu-west-1, ap-southeast-1)
  2. Deploy the stack into a supported region and omit `regions` to use it
  3. Upgrade SST in case a newer version added the region to the allow-list

Example fix

// before
new sst.aws.NextjsSite("Web", { path: "src", regions: ["us-gov-west-1"] });
// after
new sst.aws.NextjsSite("Web", { path: "src", regions: ["us-east-1"] });
Defensive patterns

Strategy: validation

Validate before calling

const SUPPORTED = ["us-east-1","us-east-2","us-west-1","us-west-2","ca-central-1","eu-west-1","eu-west-2","eu-west-3","eu-north-1","eu-south-1","eu-south-2","eu-central-1","eu-central-2","ap-south-1","ap-southeast-1","ap-southeast-2","ap-northeast-1","ap-northeast-2","ap-northeast-3","ap-east-1","sa-east-1","af-south-1","il-central-1","me-central-1"];
for (const r of regions) if (!SUPPORTED.includes(r)) throw new Error(`Unsupported region: ${r}`);

Type guard

function isSupportedRegion(r: string): r is sst.aws.SsrSiteArgs["regions"] extends (infer R)[] | undefined ? R : never {
  return SUPPORTED.includes(r);
}

Try / catch

try {
  new sst.aws.NextjsSite("Web", { path: "src", regions });
} catch (e) {
  if (String(e).includes("not supported by this component")) console.error("Use a region from SST's allow-list");
  throw e;
}

Prevention

When it happens

Trigger: Including an unsupported region string in the `regions` prop, e.g. `regions: ["us-gov-west-1"]`, `ap-southeast-5`, `cn-north-1`, or a newly launched region not yet in SST's allow-list.

Common situations: Deploying to a GovCloud/China partition; adopting a brand-new AWS region before SST adds it; picking a region string from the AWS console that isn't in SST's supported set.

Related errors


AI-assisted analysis of anomalyco/sst@a0bd20f762 (2026-08-30). Data as JSON: /api/errors/c176b883e843427f. Report an issue: GitHub.