25 for insecure traffic and 465 for secure traffic. You can use an ngrok TCP endpoint to connect to a local mail server with the following command.
ngrok works with whatever port your mail server is running on, including
587 or 2525. Just adjust the command above accordingly.TCP endpoints are only available on a free plan after adding a valid payment method to your account.