Autodiscover pointing internally but needs to point to 365


I have moved my MX and autodiscover records to office 365 but when I go to add an exchange account in Outlook it is still pointing to our old internal exchange server. Is there a specific dns record I need to add in order for the autodiscover to work for 365?
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Vasil Michev (MVP)Commented:
Depending on your version of Exchange and in general, the domain configuration, domain-joined machines might indeed end up talking to the on-prem server instead of O365. The easiest way to work around this is to instruct Outlook to bypass the local autodiscover query, by populating the reg keys mentioned in this article:

All you need for Office 365 is the Autodiscover CNAME dns record, which corresponds to the HTTP redirect method. You can block all other methods and the issue will be solved.

In general, you can also consider other options, such as stopping the relevant services, disabling the virtual dirs, disabling SCP, changing local DNS records, converting mailboxes to MEUs, deleting on-prem mailboxes, decommissioning the local server, etc. All of these are way more disruptive than just using the reg keys, so I'd stick to the simple solution.
Shreedhar EtteCommented:

If you are having Exchange 2007 or above then execute below command to set Autodiscover to null.

Get-ClientAccessServer -Identity "ServerNameHere" -AutoDiscoverServiceInternalUri $null

On your exchange server nslookup:

and create DNS zone "" in internal DNS then
create blank A records and point then IP Address you received from

After above changes restart DNS Service on Server and execute ipconfig /flushdns & ipconfig/registerdns on client machines.

Then try to configure outlook profile.

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
JRome225Author Commented:
Thank you for solutions.

@Shreedhar  the management shell did not recognize  -AutoDiscoverServiceInternalUri  as a command.
JRome225Author Commented:
Disregard..the command has to begin with "Set" instead of "Get"
Shreedhar EtteCommented:
Hi Jrome,

Thank you for the update.

Please let me know if issue fixed after make suggested changes.
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Office 365

From novice to tech pro — start learning today.