Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 18 additions & 1 deletion docs/core/tools/dotnet-dev-certs.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
---
title: dotnet dev-certs command
description: The dotnet dev-certs command generates a self-signed certificate to enable HTTPS use in development.
ms.date: 09/29/2025
ms.date: 03/29/2026
ai-usage: ai-assisted
---
# dotnet dev-certs

Expand Down Expand Up @@ -54,6 +55,20 @@ The `dotnet dev-certs` command manages a self-signed certificate to enable HTTPS

By default, the newly created certificate is not trusted. To trust the certificate, use the `--trust` option.

In .NET 10 and later, the generated ASP.NET Core development certificate includes these subject alternative names (SANs).

The `*.dev.localhost` and `*.dev.internal` SANs lets you use the certificate with `*.dev.localhost` and `*.dev.internal` hostnames for local development. The `host.docker.internal` and `host.containers.internal` SANs let you use the certificate in container-based local development scenarios:

| Type | Value |
|--|--|
Copy link

Copilot AI Mar 29, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The table header separator row uses |--|--|, which isn’t valid Markdown table syntax (each column needs at least 3 dashes). This can prevent the table from rendering correctly and might fail markdownlint. Update the separator row to use --- (or longer) per column.

Suggested change
|--|--|
| --- | --- |

Copilot uses AI. Check for mistakes.
| DNS name | `localhost` |
| DNS name | `*.dev.localhost` |
| DNS name | `*.dev.internal` |
| DNS name | `host.docker.internal` |
| DNS name | `host.containers.internal` |
| IP address | `127.0.0.1` |
| IP address | `0000:0000:0000:0000:0000:0000:0000:0001` |

To create a file that you can use with other tools, use the `--export-path` option.

## Options
Expand Down Expand Up @@ -137,6 +152,8 @@ The `dotnet dev-certs` command manages a self-signed certificate to enable HTTPS

Trusts the certificate on the local machine.

In .NET 10 and later, if you run this option inside a Windows Subsystem for Linux (WSL) instance, the command also trusts the certificate on the Windows host.

If this option isn't specified, the certificate is added to the certificate store but not to a trusted list.

When combined with the `--check` option, validates that the certificate is trusted.
Expand Down
Loading