How to Set Up Google Workspace Email With Your Domain

Email & Webmail | Updated March 2026

Google Workspace (formerly G Suite) lets you use Gmail's interface with your own domain name. Your website stays hosted with Ultra Web Hosting while Google handles your email. This guide covers the DNS changes needed, MX record configuration, and how to verify everything is working. The setup takes about 15 minutes plus up to 48 hours for DNS propagation.

Important

Back Up Your Email First

If you currently have email on our server and are switching to Google Workspace, download or back up your existing messages before changing MX records. Once MX records point to Google, new mail goes to Gmail and old mail stays on our server until you migrate it. Google has a data migration tool for importing existing email into Workspace.

01. How Google Workspace Works With Hosting

DNS records control where different services for your domain are directed:

  • A record - points your domain's website traffic to your hosting server's IP. This stays pointed at Ultra
  • MX records - point your domain's email to the mail server. These change to Google's servers
  • TXT records - used for email authentication (SPF, DKIM, DMARC) and domain verification

Changing the MX records is the only thing needed to switch email to Google. Everything else about your hosting stays the same.

02. Prerequisites

  1. Sign up for Google Workspace - at workspace.google.com. Choose your plan and add your domain during signup
  2. Verify domain ownership - Google will ask you to add a TXT record to your DNS to prove you own the domain. Add it in cPanel > Zone Editor
  3. Create your email accounts - set up users in the Google Workspace admin console before switching MX records
Tip

The verification TXT record looks like: google-site-verification=XXXXXXXXXXXXXXXX. Add it as a TXT record for your root domain in cPanel > Zone Editor. It can take up to an hour for Google to detect it.

03. Set Up MX Records

This is the critical step. You need to replace your existing MX records with Google's.

  1. Log into cPanel - go to Zone Editor (in the Domains section)
  2. Delete existing MX records - remove any MX records that point to your Ultra hosting server (e.g., mail.yourdomain.com or webXXX.ultrawebhosting.com)
  3. Add Google's MX records - add all 5 records below
Priority  Server
1         ASPMX.L.GOOGLE.COM
5         ALT1.ASPMX.L.GOOGLE.COM
5         ALT2.ASPMX.L.GOOGLE.COM
10        ALT3.ASPMX.L.GOOGLE.COM
10        ALT4.ASPMX.L.GOOGLE.COM
Warning

Make sure to delete the old MX records before adding Google's. If both sets exist, email delivery becomes unpredictable, with some messages going to Google and others to the old server.

MX record changes take anywhere from a few minutes to 48 hours to propagate worldwide. During this time, email may arrive at either the old or new server.

04. Configure SPF and DKIM

Without proper authentication records, email sent from your Google Workspace addresses may land in recipients' spam folders.

SPF Record

Update your SPF TXT record to include Google. If you also send mail from your hosting server (contact forms, etc.), include both:

v=spf1 include:_spf.google.com +a +mx ~all

If you ONLY send email through Google (no forms or scripts on the hosting server sending email):

v=spf1 include:_spf.google.com ~all

DKIM

In the Google Workspace Admin Console, go to Apps > Google Workspace > Gmail > Authenticate email. Google will give you a TXT record to add to your DNS. Add it in cPanel > Zone Editor. It usually looks like a long string of characters under the hostname google._domainkey.yourdomain.com.

DMARC

Add a DMARC record to tie SPF and DKIM together:

v=DMARC1; p=none; rua=mailto:dmarc@yourdomain.com

Start with p=none (monitoring only) and tighten to p=quarantine or p=reject after confirming everything works. For a deeper dive on email authentication, see our SPF, DKIM, and DMARC guide.

05. Fix cPanel Email Routing

This is the step most guides miss. Even after changing MX records, cPanel may still try to handle email locally.

  1. In cPanel, go to Email Routing - (in the Email section)
  2. Select your domain
  3. Change the setting to "Remote Mail Exchanger" - this tells the server to stop accepting email locally and let the MX records handle routing
Warning

If Email Routing is set to "Local Mail Exchanger" or even "Automatic," the server may intercept email destined for Google. Set it to "Remote Mail Exchanger" explicitly. This is the #1 cause of "I set up MX records but email still goes to the old server."

06. Verify Everything Works

After waiting for DNS propagation (check with our DNS Lookup tool), test these:

  1. Send a test email to your domain - from a Gmail or Outlook.com account. It should arrive in your Google Workspace inbox, not Webmail on the hosting server
  2. Send a test email from your domain - compose from Gmail and send to an external address. Check that it arrives and doesn't land in spam
  3. Check SPF/DKIM - open a received test email in Gmail, click the three dots menu > "Show original." Look for spf=pass and dkim=pass
  4. Verify your website still works - visit your domain in a browser to confirm the A record wasn't affected

07. Common Issues

Email Still Going to Old Server

Check these in order: (1) MX records are Google's, not the old server's. (2) cPanel Email Routing is set to "Remote Mail Exchanger." (3) DNS has had time to propagate (use our DNS Lookup tool to verify). (4) No old MX records still exist alongside Google's.

Contact Forms Not Working

If your website has contact forms that send email using PHP's mail() function, they'll still send from the hosting server, not through Google. The receiving server may reject these because the SPF record now points to Google. Fix: make sure your SPF record includes +a (authorizes the hosting server's IP) or configure your contact form plugin to send through Google's SMTP.

"User Not Found" Bounces

If email to your domain bounces with "user not found," you likely haven't created that email address in Google Workspace Admin. Every address you want to receive mail at must be created as a user or alias in the Google admin console.

Reverting Back to Ultra Web Hosting Email

If you want to stop using Google Workspace and go back to server-hosted email, delete Google's MX records, add back your server's MX record (pointing to your server hostname), and change cPanel Email Routing back to "Local Mail Exchanger" or "Automatic." Recreate your email accounts in cPanel if needed.

Need Help With DNS or Email Setup?

If you're having trouble getting Google Workspace working with your domain, open a support ticket and we'll check your DNS records and email routing settings.

Open a Support Ticket

Quick Recap: Google Workspace Setup

If you only do 5 things from this guide, do these:

  1. Add Google's MX records - all 5 of them, and delete the old ones
  2. Set Email Routing to Remote - in cPanel, this is the step most people miss
  3. Add SPF and DKIM records - prevents your mail from going to spam
  4. Create all your email accounts in Google Admin - before switching MX records
  5. Test sending and receiving - verify SPF and DKIM pass in the email headers

Last updated March 2026 · Browse all Email articles · See also: Email Authentication Guide

  • 0 Users Found This Useful

Was this answer helpful?

Related Articles

Email Troubleshooting Guide

Email & Webmail | Updated March 2026 Email problems are the most common support...

Sent Emails Not Showing in Sent Folder

Email & Webmail | Updated March 2026 If you send an email from your desktop or phone but...

Outlook: A Filtering Error Has Occurred -199

Email | Updated 2026 Quick Answer Error -199 is a message rule or filtering issue within...

Outlook: Unable to logon to the server using Secure Password Authentication

Email | Updated 2026 Quick Answer This error occurs when 'Log on using Secure Password...

DMARC: Domain-based Message Authentication

Email and Webmail | Updated March 2026 DMARC (Domain-based Message Authentication, Reporting,...



Save 30% on web hosting - Use coupon code Hosting30