My theme is using Bootstrap barrio theme (bootstrap_barrio) as a base theme. I'm trying to override Drupal commerce template modules/contrib/commerce/modules/order/templates/commerce-order-receipt.html.twig and it's not working for me. Even I copied that file to drupal/web/themes/my_theme/templates ,cleared the cache, Commerce is still using original template file from commerce module.

What puzzles me is that base Barrio theme also has that template and it's also not used?!?

Do I have to set somewhere what theme should be used for email templates or something? Overriding other modules templates (including commerce templates) works fine. Documentation says "The email can be customized by overriding the Twig template in your theme just as you would any other template".

1 Answer 1


Figured out what was the problem. I had to select my theme for sending emails on

Configure the Mail System admin page.


Other way some other theme is used.

  • Thanks @MilanG. That's already the second problem you asked about and helped me out :) Jan 8, 2021 at 20:07

Your Answer

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

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