How to resolve “Allowed domains are invalid” in Forms?

If you are getting this error message:

Or this one:

Then you should not place your entire Website URL in the Allowed domains field under Forms. Just place your website domain without http or https, as shown below and you are good to go.