title: Firebase authentication from localhost
body: <p>I'm working on a web project and I'd like to use firebase authentication.</p>
  
  <p>The problem is when I call <code>createUserWithEmailAndPassword</code> it fails on CORS preflight check. The response contains <a href="https://localhost:3000" rel="nofollow noreferrer">https://localhost:3000</a> while my localhost is served over http. Is there an easy way to resolve this issue?</p>
  
  <p><strong>EDIT:</strong>
  The full error message was:</p>
  
  <pre><code>Failed to load https://www.googleapis.com/identitytoolkit/v3/relyingparty/signupNewUser?key=&lt;key&gt;: Response to preflight request doesn't pass access control check: The 'Access-Control-Allow-Origin' header has a value 'https://localhost:3000' that is not equal to the supplied origin. Origin 'http://localhost:3000' is therefore not allowed access.
  </code></pre>
  
  <p><strong>UPDATE</strong></p>
  
  <p>I ended up creating a cloud functions endpoint as I have to make some validated DB updates anyway.</p>