---
title: blossom domain:create
url: "/docs/reference/cli/domain/create/"
canonical_url: https://docs.blossom88.com/docs/reference/cli/domain/create/
markdown_url: https://docs.blossom88.com/docs/reference/cli/domain/create.md
summary: Create a domain
categories:
- cli
- reference
---

# blossom domain:create

Create a domain

## Usage

    blossom domain:create [--data DATA]

## Flags

| Flag | Description |
| --- | --- |
| `--data, -d` | YAML or JSON data, a path to a data file, or an HTTP(S) URL |

Examples:

    blossom domain:create --data domain.yml
    blossom domain:create --data '{"domain":{"environment_id":"environment-100","dns_name":"www.example.com","main":true}}'
    blossom domain:create --data '{"domain":{"environment_id":"environment-100","dns_name":"*.example.com","dns_provider_id":"dns_provider-100"}}'
    blossom domain:create --data '{"domain":{"environment_id":"environment-100","dns_name":"api.example.com","service_id":"service-100"}}'

Creates a domain for an environment.

A domain reaches the environment's `web` Service, except the paths in the
environment's routes, such as `/cable` (`blossom route:list`). Set `service_id` to send the whole
domain to another public Service instead, such as an `api` or `mcp` process
with its own host.

Blossom infers the SSL mode from `dns_name`: wildcard names such as
`*.example.com` use Wildcard HTTPS, and other names use Automated HTTPS. Set
`mode` only when you need `self_signed` or `http_only`.

Supported SSL modes:

- `https_automated`
- `self_signed`
- `http_only`
- `dns_wildcard`

Wildcard HTTPS requires a wildcard `dns_name` such as `*.example.com` and a
`dns_provider_id`. Blossom uses the DNS provider credentials centrally to issue
the wildcard managed cert; customer load balancers restore the cert bundle and
do not need Caddy DNS plugins.
