Xamarin – Did not find reference matching RestoreAssemblyResources AssemblyName metadata

Did you recently remove a package, but Visual Studio insists it’s there? Or did you readd it and VS seems to disagree? People on the Xamarin Forums tend to get good luck cleaning/rebuilding, and it miraculously starts working again for them. I wasn’t so fortunate and wasted a lot of time taking their word for it.


My exact error message

Error Did not find reference matching RestoreAssemblyResources AssemblyName metadata 'Google.MobileAds, Version=, Culture=neutral, PublicKeyToken=null' iosTests

If you’re like me, you’ve tried readding the package, modifying your packages.config file and still nothing is working

Here’s what you need to do:

  1. Locate your  .csproj file and open it in a text editor (Double clicking opens it in VS)
  2. Press CNTRL + F and search for the offending library
  3. Comment out the entry or delete it
  4. Build the project again (Since it’s Xamarin, it will take a lifetime to build) and it will hopefully work again!
  5. Success! 

I spent days trying to figure this out. When we as Xamarin developers run into issues like this, we need to share our solutions since there is little to no support from Xamarin. I hope all my fellow Xamarin developers will find this useful!

15 comments for “Xamarin – Did not find reference matching RestoreAssemblyResources AssemblyName metadata

  1. Gilbyjazz
    March 7, 2017 at 12:08 pm

    Hey Evan.

    This was indeed a fast fix for my problem.
    I am not sure if this will cause other issues – but one problem at a time.

    I appreciate your mindset.
    Xamarin is indeed a ..tricky thing.. and every small information can help.


    • Evan Parsons
      March 7, 2017 at 2:21 pm

      Hi Gilbyjazz,

      My code still compiles and is production ready now, so it can’t be all that bad 🙂


  2. March 19, 2017 at 1:41 am

    Thanks for the solution!


    • Evan Parsons
      March 20, 2017 at 11:42 am

      Hey Sovit,

      No problem!


  3. John
    May 16, 2017 at 8:56 am

    I love you man!

    • Evan Parsons
      May 16, 2017 at 10:07 pm

      Love received!!! Glad I could help!

  4. Hugo
    June 30, 2017 at 11:27 am


  5. RoshTheMosh
    July 27, 2017 at 5:12 pm

    Your solution worked well for me, Glad to have come across this blog post

    Thank you

    • Evan Parsons
      July 28, 2017 at 1:56 am

      Not a problem!

  6. Mark Reynolds
    October 28, 2017 at 5:39 pm

    Thanks for posting; very helpful.

    • Evan Parsons
      October 28, 2017 at 7:26 pm

      No problem Mark

  7. Asmaa
    April 1, 2018 at 2:55 am

    This help me thanks

  8. Waqas Ilyas
    May 14, 2018 at 9:42 am

    Thanks man, it was very helpful, worked for me

  9. hassan
    August 29, 2018 at 5:21 pm

    thanks very much

  10. Danny
    April 11, 2019 at 7:51 pm

    This saved me today! Thank you!

Leave a Reply

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