Redirect GitHub Pages from Subdomain to the Top-Level Domain

1 · Christian Cleberg · Aug. 22, 2020, midnight
Short answer Step 1 Add a new file CNAME to your GitHub Pages repository containing only one line: your top-level domain name. E.g.: example.com Step 2 [Optional] but highly recommended 2.1: Remove all other top-level records (prefixed with @) of type A from your DNS configuration. 2.2: Remove a CNAME record for the second-level domain www if it is present. Step 3 Add these 5 entries to the very top of your DNS configuration: @ A 185.199.108.153 @ A 185.199.109.153 @ ...