Open Closed

Change Default Email sender and host #8993


User avatar
0
nabass created

hi I would like to configure my custom SMTP settings as the default email sender configuration in my ABP application, rather than using the default ABP settings (like "noreply@abp.io" and "127.0.0.1"). How can I make my custom settings persist and always be used by the application, even after restarting the app or making other configuration changes? i have attachment imgs for default email and email i want to use when open this section so where can i change it? thanks


1 Answer(s)
  • User Avatar
    0
    berkansasmaz created
    Support Team .NET Developer

    Hi,

    If you don't use the Setting Management module, you can simply define the settings inside your appsettings.json file:

    "Settings": {
      "Abp.Mailing.Smtp.Host": "127.0.0.1",
      "Abp.Mailing.Smtp.Port": "25",
      "Abp.Mailing.Smtp.UserName": "",
      "Abp.Mailing.Smtp.Password": "",
      "Abp.Mailing.Smtp.Domain": "",
      "Abp.Mailing.Smtp.EnableSsl": "false",
      "Abp.Mailing.Smtp.UseDefaultCredentials": "true",
      "Abp.Mailing.DefaultFromAddress": "noreply@abp.io",
      "Abp.Mailing.DefaultFromDisplayName": "ABP application"
    }
    
    

    See more: https://abp.io/docs/latest/framework/infrastructure/emailing#email-settings

Boost Your Development
ABP Live Training
Packages
See Trainings
Mastering ABP Framework Book
Do you need assistance from an ABP expert?
Schedule a Meeting
Mastering ABP Framework Book
The Official Guide
Mastering
ABP Framework
Learn More
Mastering ABP Framework Book
Made with ❤️ on ABP v9.3.0-preview. Updated on April 16, 2025, 12:13