<@U04UQ68083H> How to customize the email template...
# ory-copilot
l
@chilly-king-10285 How to customize the email template which is getting sent during the verification code
c
A message from kapa.ai
To customize the email template for verification codes in Ory, you can follow these steps: 1. List all your projects and get the Ory Identities config file:
Copy code
shell ## List all available projects   ory list projects      ## Get config   ory get identity-config <project-id> --format yaml > identity-config.yaml
2. Add your Base64-encoded custom message templates to the config:
Copy code
shell identity-config.yaml courier:    smtp:    from_name: MyProject via Ory    templates:    verification:    invalid:    email:    body: { "html": "<base64://ENCODED_HTML_TEMPLATE>", "plaintext": "<base64://ENCODED_PLAINTEXT_TEMPLATE>" }    valid:    email:    body: {}
3. Upload the edited config:
Copy code
shell   ory update identity-config <project-id> --file updated_config.yaml
In the Ory Network, you can use only Base64-encoded templates.
http://
or
file://
URIs are not supported. If you provide custom templates using unsupported methods, the system uses the default templates. For more details, you can refer to the [Ory documentation](https://www.ory.sh/docs/kratos/emails-sms/custom-email-templates#using-custom-message-templates).