# Emails and texts

> The emails and text messages 9in sends, how to change their wording per language, and the sender details.

Source: https://9in.io/docs/emails-and-texts/

9in sends two kinds of messages to users of tenants that store users in 9in:

| Message | Sent when | By |
|---|---|---|
| Sign-in code | Someone signs in with a one-time code, or verifies an email address | Email, or SMS for phone numbers |
| Password reset code | Someone asks to reset their password | Email, or SMS for phone numbers |

With [your own user database](https://9in.io/docs/own-database/), 9in sends you an `otp.requested` event instead and you deliver the code.

## Preview and change them

**Emails** in the console shows each message as users get it: the email with its inbox header, or the text message with how many SMS it is billed as. **Click the subject or the text in the preview to change it**, in each of your languages; it's saved as a [translation](https://9in.io/docs/themes/#texts-and-languages).

The texts use placeholders that 9in fills in when sending:

| Placeholder | Becomes |
|---|---|
| `{app}` | Your tenant's name |
| `{code}` | The code (keep it in the text) |
| `{minutes}` | How long the code is valid |

## What the email looks like

- **Logo** from Branding. Most email clients don't show SVG images, so with an SVG logo emails use your icon (or your name) instead; upload a PNG version to show it.
- **Code** in a large box, in your theme's accent color (when it's dark enough to read).
- **Footer** with your name and the links from Branding (privacy policy, terms, support).

Emails are sent as HTML with a plain-text part.

## Sender

**Emails → Sender**:

- **Sender name:** shown as the "From" name. Default: your tenant's name.
- **Reply-to address:** where replies go instead of the no-reply sender.

## Text messages

SMS go through 9in's Twilio account on paid plans, or your own Twilio account (**Security → SMS delivery**), only to the countries you allow. Keep them short: letters outside the basic Latin set (Arabic, Cyrillic, emoji…) make each SMS hold 70 characters instead of 160.

With your own Twilio account you can give a **Twilio Verify** service (`VA…`) instead of, or as well as, a sender number. Twilio then sends the code in Verify's own wording, translated into the user's language and naming your app, from a sender registered for each country (no number to buy, no US 10DLC registration). If the Verify service has custom codes enabled (Twilio turns them on when asked), the code is 9in's own, with your code length, and 9in tells Verify when it was used. Otherwise Twilio generates the code, with the service's code length, and 9in checks the user's entry with Twilio. Either way your code lifetime and attempt limits apply. The text you write here is not used for those messages. The console shows when this applies, including when 9in's own account sends through Verify.

## Languages

Each user gets messages in the language of the page they were on. The built-in texts exist in English, Arabic, Chinese, French, German, Hebrew, Japanese, Persian, Russian, Spanish and Turkish; you can change any of them, and texts you don't translate fall back to English.
