title: Enable https using UVICORN
body: <p>I tried this tutorial (<a href="https://dev.to/rajshirolkar/fastapi-over-https-for-development-on-windows-2p7d" rel="nofollow noreferrer">https://dev.to/rajshirolkar/fastapi-over-https-for-development-on-windows-2p7d</a>) and then when I went to my browser but I cannot access my localhost address using https, if I try http it works but I need to use HTTPS.</p>
  <p>Here is the code I tried:</p>
  <pre><code>import uvicorn
  
  if __name__ == &quot;__main__&quot;:
      uvicorn.run(&quot;app.api:app&quot;,
                   host=&quot;localhost&quot;,
                   port=8432, 
                   reload=True,
                   ssl_keyfile=&quot;./key.pem&quot;, 
                   ssl_certfile=&quot;./cert.pem&quot;)
  </code></pre>