--- last_review: "" last_reviewer: "" documented_code: [ ] metadata: target_user: "Administrator" --- ```{tags} howto, administrator, email ``` # Configure Email for Server-Side Scripts This guide shows how to configure LinkAhead to send emails from [server-side scripts](/tutorial/scripting/server_side_scripting/server_side_scripting.md). Email sending is handled by the pylinkahead `send_email` function, which reads its settings from the `[Email]` section of `caosdb-server/scripting/home/pylinkahead.ini`. ## Prerequisites - Server-side scripting is configured and working. See the [server-side scripting documentation](/tutorial/scripting/server_side_scripting/server_side_scripting.md). - Your institution's SMTP server is reachable from the LinkAhead host, and you have the hostname, port, and credentials for it. ## Steps Add an `[Email]` section to `caosdb-server/scripting/home/pylinkahead.ini`. Port 587 with STARTTLS is the most common setup for institutional SMTP servers: ```ini [Email] smtp_server=smtp.example.com smtp_port=587 smtp_starttls=yes smtp_username=your_username smtp_password=your_password from_address=LinkAhead bcc_append=admin@example.com ``` If your server requires implicit TLS (port 465) instead of STARTTLS, replace `smtp_starttls=yes` with `smtp_tls=yes` and set `smtp_port=465`. For the full list of supported options, see the [`send_email` API documentation](/reference/pylib/api/linkahead.utils.email.rst).