title: Change the database in which ASP.NET Identity stores user data
body: <p>We have created a new ASP.NET 4.5.1 project as follows:</p>
  
  <ul>
  <li>Visual Studio 2013</li>
  <li>New Project</li>
  <li>Visual C# </li>
  <li>Web </li>
  <li>ASP.NET Web Application </li>
  <li>Web API </li>
  <li>Change Authentication </li>
  <li>Individual User Accounts </li>
  <li>Okay > Okay</li>
  </ul>
  
  <p>In the solution explorer > App_Start > Startup.Auth.cs file there is the following code which configures ASP.NET Indentity. How do we change the database in which the UserManager stores user data?</p>
  
  <pre><code>static Startup()
  {
      PublicClientId = "self";
  
      UserManagerFactory = () =&gt; new UserManager&lt;IdentityUser&gt;(new UserStore&lt;IdentityUser&gt;());
  
      OAuthOptions = new OAuthAuthorizationServerOptions
      {
          TokenEndpointPath = new PathString("/Token"),
          Provider = new ApplicationOAuthProvider(PublicClientId, UserManagerFactory),
          AuthorizeEndpointPath = new PathString("/api/Account/ExternalLogin"),
          AccessTokenExpireTimeSpan = TimeSpan.FromDays(14),
          AllowInsecureHttp = true
      };
  }
  </code></pre>