Why am I getting 'Unable to find package Microsoft.AspNetCore.App.Ref.' error?

Richard Wheeler 1 Reputation point

I am running Visual Studio 2019 and trying to develop a .NET Core 3,1 ASP MVC application. I was working just fine yesterday but this morning I opened my project and began getting 'Unable to find package Microsoft.AspNetCore.App.Ref.' error and Unable to find package Microsoft.NETCore.App.Host.win-x64 errors.

My project is file is as follows:

<Project Sdk="Microsoft.NET.Sdk.Web">



What happened? How did I lose these packages and how can I get them back?

A set of technologies in the .NET Framework for building web applications and XML web services.
4,120 questions
{count} votes

1 answer

Sort by: Most helpful
  1. Marcell Nagy 1 Reputation point

    Try to clean the solution, then rebuild. Looks like this was a caching problem.

    0 comments No comments