# Email Templates Deep Dive {#email-templates-deep-dive}


Customize and manage transactional email templates.


## Overview {#overview}


Gauzy sends transactional emails for:

- Welcome emails
- Password resets
- Timesheet approvals
- Invoice notifications
- Team invitations
- Task assignments


## Template Engine {#template-engine}


Templates use **Handlebars** syntax:

```html
<h1>Welcome to {{organizationName}}, {{firstName}}!</h1>
<p>Your account has been created. Click below to get started:</p>
<a href="{{loginUrl}}">Login to Gauzy</a>
```


## Available Templates {#available-templates}


| Template              | Trigger              |
| --------------------- | -------------------- |
| `welcome-user`        | New user created     |
| `invite-user`         | Team invitation      |
| `password-reset`      | Password request     |
| `timesheet-submitted` | Timesheet submitted  |
| `timesheet-approved`  | Timesheet approved   |
| `timesheet-denied`    | Timesheet denied     |
| `invoice-sent`        | Invoice emailed      |
| `payment-received`    | Payment confirmation |
| `task-assigned`       | Task assignment      |


## Customizing Templates {#customizing-templates}


1. Go to **Settings** → **Email Templates**
2. Select template to edit
3. Modify the HTML and subject line
4. Use variables: `{{firstName}}`, `{{organizationName}}`, `{{link}}`
5. Preview and save


## Template Variables {#template-variables}


| Variable               | Available In           |
| ---------------------- | ---------------------- |
| `{{firstName}}`        | All templates          |
| `{{lastName}}`         | All templates          |
| `{{email}}`            | All templates          |
| `{{organizationName}}` | All templates          |
| `{{link}}`             | Password reset, invite |
| `{{amount}}`           | Invoice, payment       |
| `{{invoiceNumber}}`    | Invoice templates      |


## SMTP Configuration {#smtp-configuration}


```env
MAIL_FROM_ADDRESS=noreply@your-domain.com
MAIL_HOST=smtp.your-provider.com
MAIL_PORT=587
MAIL_USERNAME=your-username
MAIL_PASSWORD=your-password
```


## Related Pages {#related-pages}


- [Email History Endpoints](https://sourcey-gauzy.pages.dev/api/email-history-endpoints/index.md) — email API
- [Notification System](https://sourcey-gauzy.pages.dev/features/notification-system/index.md) — notifications
