Lack of URL encoding in preview URLs breaks AWS CloudFront

Builder content link

Builder public api key

Detailed steps to reproduce the bug

  1. Create a Next.js application for Builder
  2. Deploy it with SST (which deploys it to AWS)
  3. Try to create a page and preview it via Builder

Notice that on step 3, you’ll get the following error:

The link that the preview is trying to hit is

If you take the last query string parameter and URL encode it, you get the following link:

That link works. So the issue is that AWS Cloudfront can’t handle the : in the query string. In my opinion, this query string should be URL encoded to start never mind that it’s breaking my specific application.

Code stack you are integrating Builder with
Next.js, SST, & AWS.

Hi @vrio_dave,

We really appreciate you reporting this possible issue to us, we are going to investigate this further and deploy a possible solution. We will try to update you as soon as we have any insights on this. Thank you!

Hi @manish-sharma ,
Has there been any update on this? I am also running into the same issue with deploying using SST.

This is the query that CloudFront is blocking, “:” characters are not allowed in query parameters.


I have been unable to find a way to configure AWS to ignore this problem. The only workaround I have found is to edit the query in the iframe of the visual builder, allowing me to live edit and publish changes. However, this is not optimal as I have to do this every time I load the page.