Production Web Payments SDK returns 401 on pci-connect hydrate

Hello Square Developer Support,

I am integrating Square Web Payments SDK in Production for my business website.

When the page calls payments.card(), the card form does not render. Chrome DevTools shows that the Square pci-connect payments hydrate request returns 401 Unauthorized.

I verified that my website uses the Production Application ID and Production Location ID, and I reproduced the issue in Chrome Incognito.

Could you please verify whether Web Payments SDK and card-not-present API payments are enabled for my Production application and location, and whether an account or application restriction is causing this 401 error?

I can provide the public Application ID and Location ID privately if needed. I will not share my access token.

Thank you.

Update: I added the required Production Content Security Policy to the live page and retested in Chrome Incognito.

The CSP is now present and allows web.squarecdn.com and pci-connect.squareup.com. The issue still persists: payments.card() does not render and the pci-connect hydrate request returns 401 Unauthorized.

Could you please check the Production application and location authorization on the Square side?

Can you confirm you are using the correct script source (not domains) when loading the SDK and initializing with your app id?

<script src="https://sandbox.web.squarecdn.com/v1/square.js"></script>

But for production it should look like this:

<script src="https://web.squarecdn.com/v1/square.js"></script>

Can you also verify you are using the correct app id for the corresponding environment (production vs sandbox).

If you think you’re using both, please DM me the application ID and I can look into it.