I need to send an email after a customer try to save a new address in his address book

  • are you talking about frontend? Nov 3, 2021 at 10:08
  • Yes, in customer dashboard
    – sara ben
    Nov 3, 2021 at 10:26
  • Kindly check the answer I posted. Nov 3, 2021 at 10:52

2 Answers 2


You can use below events for customer address.

<event name="customer_address_save_after">
    <observer name="customer_addres_after_save_event_observer" instance="Vendor\Extension\Observer\AfterAddressSaveObserver" />


<event name="customer_address_save_before">
    <observer name="customer_address_before_save_event_observer" instance="Vendor\Extension\Observer\BeforeAddressSaveObserver" />
  • Could you please explain where to put this code, Thank you for your answer
    – sara ben
    Nov 3, 2021 at 11:09
  • You need to create events.xml into extension and put the code there. Nov 6, 2021 at 17:37

You should create etc/frontend/events.xml file in your module and post there event from Dhiren Vasoya comment. Then create the class Vendor\Extension\Observer\BeforeAddressSaveObserver OR Vendor\Extension\Observer\BeforeAddressSaveObserver depending on your event name and send email inside the class. You can google a little and find the way how to send email with custom template and parameters.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.