RavenDb 2.0 on IIS with Windows Authentication returns a 401 Unauthorized #ravendb

Written on May 17, 2013

If you're hosting RavenDb 2.0 on IIS 7.5 / 8 and you have activated Windows authentication according to the official RavenDb documentation, your browser might keep prompting for the username and password and show you "Unauthorized" after the third attempt when you're trying to create a new database:

image

If this is the case, you should set

<add key="Raven/AnonymousAccess" value="Admin" />

inside the web.config

Now you can create (and delete) new databases using Windows Authentication:

image