how to set up google domain with github

How to Connect Google Domain to GitHub

By Melissa Moore
AD

Are you considering how to associate your professional brand with a custom domain on GitHub? You've landed in the right place. In this comprehensive guide, we will walk you through the process of setting up a Google domain with GitHub, ensuring your online presence is as professional and polished as your coding skills. Let's dive right in!

Before we start, ensure you have a Google domain and a GitHub account. If you don't have a Google domain, head over to Google Domains to register one. Once you're all set, let's connect your Google domain to GitHub.

Connecting Your Google Domain to GitHub

With great power comes great responsibility (and sometimes, a few clicks). Here's how to connect your Google domain to GitHub.

AD
GoDaddy Domain with GitHub Pages
GoDaddy Domain with GitHub Pages
How To add a Custom Domain On Github Pages
How To add a Custom Domain On Github Pages
How to Verify or Approve a Domain for Your GitHub Organization?
How to Verify or Approve a Domain for Your GitHub Organization?

Your first step involves adding a TXT record to your domain settings. This verifies that you own the domain and sets the stage for the association with your GitHub account.

Adding a TXT Record to Your Domain

First, log in to your Google Domains account. Navigate to the 'DNS' tab and click on 'Add new record set'. Select 'TXT' from the list of record types. Then, enter the provided value from GitHub in the appropriate field. Click 'Save' to finalize the changes.

GitHub Basics Tutorial - How to Use GitHub
GitHub Basics Tutorial - How to Use GitHub
How the Heck Do I Use GitHub?
How the Heck Do I Use GitHub?

It may take a few minutes for the record to propagate. Once it does, move on to the next step.

Claiming Your Domain on GitHub

Now, log in to your GitHub account. At the top-right corner of your screen, click your profile photo, then select 'Settings'. In the left sidebar, select 'Domains'. Click on 'New Domain' and enter your domain name.

AD

Next, you'll be asked to verify that you own the domain. GitHub provides a unique record to add to your domain's DNS settings. Follow the on-screen instructions to add this record to your Google Domains account, just like we did with the TXT record.

Configuring GitHub Pages with Your Custom Domain

With your domain connected, it's time to set up GitHub Pages to publish your personal website or portfolio. GitHub Pages allows you to host your website directly from your GitHub repository, making it easy to edit and update your content.

Head back to your GitHub account settings and navigate to the 'GitHub Pages' section. Select the repository you want to publish as a website, then click 'Save'.

AD

Enabling GitHub Pages

Navigate to the 'Settings' tab of your repository. Scroll down to the 'GitHub Pages' section. Under 'Source', select your 'main' branch, make sure 'Root path' is set to '/', and click 'Save'.

It might take a few minutes for your website to go live. Once it does, you can view your site by entering your custom domain in your web browser.

Creating a Custom 404 Page

A 404 page is what visitors see when they try to access a non-existent page on your website. Creating a custom one adds a touch of professionalism to your site. In your repository, create a file named '404.html' in the root directory. Add your custom content, and GitHub Pages will automatically use this page when necessary.

AD

Setting up a Google domain with GitHub not only makes your online presence more professional but also opens up new avenues for showcasing your projects and engaging with your audience. So, go ahead and personalize that domain, and let your creativity shine!

AD