# Mailgun Setup

{% hint style="info" %}
Gravity supports any email service supported by [Nodemailer](https://nodemailer.com/). If you don't want to use Mailgun please refer to the [Email Notifications](/gravity-server/email-notifications.md) section for instructions on how to change to another provider.&#x20;
{% endhint %}

[Mailgun](https://mailgun.com/) is an easy-to-use and very cost-effective transactional email provider with great analytics tools.&#x20;

## 1. Register a Mailgun Account

Head over to [Mailgun](https://signup.mailgun.com/new/signup) and [register your account.](https://signup.mailgun.com/new/signup)

## 2. Setup Your Domain

Follow the [Mailgun setup instructions](https://documentation.mailgun.com/en/latest/quickstart-sending.html) to set up and verify your domain.

You will also need access to your domain control panel to edit the DNS settings. It can take up to 48 hours for your domain to be verified but usually only takes a few minutes.

## 3. Copy Your API Key

Log into your [Mailgun dashboard](https://app.mailgun.com/app/dashboard) and copy your private API key from the sidebar. You'll need this in the next step.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.usegravity.app/gravity-server/installation/mailgun-setup.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
