How to connect your domain to Google Sites
Want to connect your Porkbun domain to your Google Sites page? No problem!
According to this article from Google, you will need to verify ownership of your domain and connect to it with a CNAME record. You'll need to decide ahead of time whether or not you'll want to use a custom subdomain (subdomain.domain.tld) instead of "www" (www.domain.tld).
Let's get started!
Log in to your Google Site and click the "Publish" button in the upper-right corner. If you have already published the site, click the arrow button next to "Publish" and click "Publish Settings..." in the drop-down menu. Click MANAGE in the Custom URL settings section to add a Custom URL.
Enter your domain name using the sub-domain you would like to use (generally www). Google Sites does not support use of the root domain. You will be prompted to verify your ownership of the domain. Click the "verify your ownership" link to proceed. This will open up the verification page in a new tab.
You will be prompted to choose a domain provider. Choose "Other" from the dropdown menu to continue to a manual setup page. You will be shown instructions to create a TXT record. Select and copy the entire record
Login to your Porkbun account. You should end up on your domain management page. If you are already logged in, click on ACCOUNT in the top right corner and select "Domain Management." Then click on Details for your domain and click on the "Edit" link under DNS Records.
Select "TXT" from the Type dropdown menu. Leave the host blank and paste the record from earlier into the Answer field, then click Add.
Add a second record, selecting "CNAME" as the type. Under Host, list the subdomain you chose earlier set the answer to ghs.googlehosted.com then click Add.
Return to the Google verification page and click the "Verify" button at the bottom. If the TXT record was setup correctly you should receive a message that verification was successful.
Return to the Google Sites tab. Your Custom URL should now show a checkmark indicating the domain has been verified. Click the "Assign" button.
Finally, if you haven't already, click the "Publish" button to publish your site.
That's it! If you did everything correctly, your subdomain should begin resolving to your Google Sites page.
Enable Forwarding from the Root domain to your Subdomain
To enable forwarding from the root domain, sign into Porkbun and go to the Domain Management page. Click the "Details" button for your domain. Click the "Edit" link under URL Forwarding.
Enter the URL of your chosen subdomain, including https. Click the "Toggle advanced settings" link. Check both of the boxes at the bottom to "Include the requested URI path in the redirection" and "Only delete URL forwarding specific DNS records" to prevent your other records from being deleted. Click the "Submit" button to finish setting up the URL redirect.