title: How to redirect to a different route in Blazor Server-side
body: <p>In Blazor Client a redirection can be achieved using</p>
  
  <pre><code>using Microsoft.AspNetCore.Blazor.Browser.Services;
  (...)
  BrowserUriHelper.Instance.NavigateTo("/route")
  </code></pre>
  
  <p>This does however not work in a Blazor Server project, as it generates the following error:</p>
  
  <blockquote>
    <p>Unable to cast object of type 'Microsoft.AspNetCore.Blazor.Server.Circuits.RemoteJSRuntime' to type 'Microsoft.JSInterop.IJSInProcessRuntime'.</p>
  </blockquote>
  
  <p>How does a redirect in Blazor-Server look like?</p>