Remote SharePoint site connections are not supported.

When I do SharePoint development, I usually work with multiple web applications. One for My Site, one for publishing, one for search, etc. I also use host headers to identify each web application so that I don’ t have to remember different port numbers.

On my developer box, I add a number of entries to the hosts file that map each host name to This has worked on all previous versions of SharePoint and Visual Studio, but stopped with the Beta version of the Visual Studio extensions for SharePoint 2013.

When trying to use as the Site Url

You end up with the following error message:

If I enter http://machinename, everything works as expected.

Why do I get this error message? Everything is running on my local machine. I only have one machine and all host names resolve to the loopback address.
Refusing to accept this limitation, I started exploring the extension code written by Microsoft.

When setting this property, the code makes a lot of checks. One of them is the IsLocalByIp(). The url being passed is the one you type in the property window.

If you copy this code to a console application and run it, it’s easy to discover why things are not working. The hostAddresses variable contains all the addresses of the computer except the address. The second variable contains the address specified in the hosts file. Since this is not considered a local address, the test fails.

Hopefully Microsoft will add an exception rule for in this code. Until then, the solution is to use the IP address of your machine in the hosts file, not If you have a dynamic IP address, remember to update the host file.


3 Responses to Remote SharePoint site connections are not supported.

  1. Thanks for the tip! This saved me a lot of time šŸ™‚

  2. another way to do it would be

    1 ) go to C:\Windows\System32\Drivers\etc

    open the hosts file and set the dynamic IP of your machine facing you site url


    2) save and try again

Leave a Reply

Please log in using one of these methods to post your comment: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: