.net – Visual Studio 2026 fresh install keeps giving “Internal Server Error”


I just installed Visual Studio 2026. However, whenever I try to run my project, I constantly get an Internal Server Error.

The error shows up both inside the IDE and in the browser. If I close and reopen Visual Studio, it sometimes works for a short time, but then the same error comes back. I already did a clean install, but the issue persists.

What I’ve tried so far:

  1. Reinstalled Visual Studio.
  2. Cleared IIS Express and browser cache.
  3. Rebuilt the project.

None of these solved the issue.

One of the internal errors:

StreamJsonRpc.RemoteInvocationException: Service of type 'Microsoft.CodeAnalysis.Options.ILegacyWorkspaceOptionService' is required to accomplish the task but is not available from 'RemoteWorkspace' workspace.
   at StreamJsonRpc.JsonRpc.<InvokeCoreAsync>d__172`1.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at Microsoft.CodeAnalysis.Remote.BrokeredServiceConnection`1.<TryInvokeAsync>d__14`1.MoveNext()
RPC server exception:
System.InvalidOperationException: Service of type 'Microsoft.CodeAnalysis.Options.ILegacyWorkspaceOptionService' is required to accomplish the task but is not available from 'RemoteWorkspace' workspace.
      at Microsoft.CodeAnalysis.Host.HostWorkspaceServices.GetRequiredService[TWorkspaceService]()
      at Microsoft.CodeAnalysis.Workspace..ctor(HostServices host, String workspaceKind)
      at Microsoft.CodeAnalysis.Remote.RemoteWorkspaceManager.<>c.<.cctor>b__11_0()
      at System.Lazy`1.ViaFactory(LazyThreadSafetyMode mode)
   --- End of stack trace from previous location ---
      at System.Lazy`1.CreateValue()
      at Microsoft.CodeAnalysis.Remote.RemoteAssetSynchronizationService.<>c__DisplayClass6_0.<<SynchronizePrimaryWorkspaceAsync>b__0>d.MoveNext()
      at Microsoft.CodeAnalysis.Remote.BrokeredServiceBase.GetWorkspaceServices()
      at Microsoft.CodeAnalysis.Remote.RemoteLegacySolutionEventsAggregationService.<ShouldReportChangesAsync>b__2_0(CancellationToken cancellationToken)
      at Microsoft.CodeAnalysis.Remote.BrokeredServiceBase.RunServiceImplAsync[T](Func`2 implementation, CancellationToken cancellationToken)
      at Microsoft.CodeAnalysis.Remote.BrokeredServiceBase.RunServiceImplAsync(Func`2 implementation, CancellationToken cancellationToken)

There are ~10 errors like this. I close them but they are reopening. 🙁

Question:

Why am I constantly getting Internal Server Error in Visual Studio 2026, and how can I fix this?

Leave a Reply

Your email address will not be published. Required fields are marked *