On this page
What this issue is
Many sites do not store the email body. They call an ESP such as SendGrid, Postmark, Mailgun or Amazon SES and say: use template d-1234... with this data. The ESP fills in the name, order number or form answers and sends the email.
Why it costs you leads or sales
The affected email silently stops. Depending on the template, that can be a lead notification to your sales team, an order confirmation, a booking confirmation, a password reset or a welcome email. Buyers worry their order failed, leads are never followed up, and support tickets rise.
- Visitor submits formForm or checkout completes
- Site calls ESPSends old template ID
- ESP rejects sendTemplate not found
- Email deliveredNever sent
- Follow-upLead or buyer gets nothing
The visitor sees success, but the ESP rejects the send.
The submission succeeds on screen, but the template call fails behind the scenes.
How to check if your site has it
Check recent template changes
In your ESP, look at the template list and any activity or audit log. Note templates deleted, duplicated or recreated recently.
Check the ESP's failed sends
Open the activity, logs or API errors view in your ESP and look for errors such as template not found or invalid template ID.
List the IDs your site uses
Search your plugin settings, theme code, automation tool or CRM workflows for template IDs. Compare each one with the IDs that exist in the ESP now.
Send a real test
Submit your own form, place a test order or trigger the workflow, then check the inbox and the ESP log.
How to fix it
You have two options: restore or recreate the template, then update the ID everywhere it is used; or point the site to another existing template. Either way, the ID in the site must match a live template.
Open your mail plugin settings
Where the ESP is connected through a plugin (for example a form or WooCommerce email add-on), find the field holding the template ID. The location depends on the plugin.
Paste the live ID
Copy the current template ID from the ESP and save. Check every form or email type that has its own template field.
Check the email app or Flow
Shopify's own notifications do not use ESP IDs. If an app or Shopify Flow action sends through your ESP, open its settings and update the template ID there.
Check custom ESP or webhook actions
If a workflow calls your ESP through a webhook or custom action, edit that action and replace the template ID in the request body.
Move the ID to config
Search the codebase for the old ID, replace it, and store the ID in an environment variable so it is changed in one place.
Log ESP errors
Log the response status and body whenever the ESP call fails so a bad ID is visible.
const sgMail = require('@sendgrid/mail');
sgMail.setApiKey(process.env.SENDGRID_API_KEY);
sgMail.send({
to: 'lead@example.com',
from: 'hello@yourdomain.com',
templateId: process.env.LEAD_TEMPLATE_ID,
dynamicTemplateData: { name: 'Sam' }
}).catch(err => {
console.error('ESP error', err.response && err.response.body);
});How to confirm it's fixed
- Submit a test form or order and receive the email in your inbox
- The ESP log shows the send as accepted, with no template errors
- Merge fields (name, order number) are filled in, not blank
- Every form, order status or workflow that uses a template has been tested
- The email did not land in spam
How to prevent it happening again
Risky
- Templates deleted without checking usage
- IDs pasted in many places
- ESP errors not logged
Safer
- Template list documented with where each is used
- IDs stored in one config value
- Errors logged and alerted
- Test send after any template change
How FunnelGuard handles this
FunnelGuard detects this only partly. It runs your real journey on a schedule, submits a test lead and uses its email_content checks to look at the email that arrives. If the template ID is broken and no email arrives, or the email arrives with the wrong or empty content, you get an alert with a screenshot and a likely cause, after a re-check from a second region.
- List every template and where it is used, and review it after each ESP change
- Check the ESP error log weekly for template not found errors
- Trigger non-tested emails (password reset, shipping, booking changes) monthly
- Test after any template is deleted, duplicated or recreated
Questions people ask
Why is my transactional email not sending after I deleted a template?
Your site is probably still sending the old template ID, and the email provider rejects it as not found. Update the site, plugin or workflow to use the ID of a live template, then send a test.
How do I find the template ID my site is using?
Search plugin settings, theme or app code, automation actions and environment variables for the ID string. Compare it with the template IDs listed in your ESP dashboard.
Does recreating a deleted template restore the old ID?
Usually not. A recreated or duplicated template gets a new ID, so you must update every place that used the old one.
Why does the form say success but no email arrives?
The form can finish before the email call is made or without checking its result. If the ESP rejects the template ID, the visitor still sees success while the email is never sent.
Where do I see the template not found error?
Check your ESP's activity, logs or API error view, and your own server or plugin logs. The error usually mentions an invalid or missing template ID.
Can FunnelGuard tell me a template was deleted?
No. It checks the outcome through its email_content checks on journeys it runs, such as a missing or wrong test email. It does not inspect your ESP account or template list.
How can I stop this from happening again?
Edit templates instead of deleting them, keep IDs in one config value, log ESP errors, and send a test after any template change.
Related issues
- DLV-064SendGrid/Mailgun/Postmark/SES account suspendedFix guide
- DLV-065ESP API key revoked or rotated without updating the siteFix guide
- DLV-071Sender identity unverified in the ESPFix guide
- DLV-075Email sent from ESP test/sandbox mode, never deliveredFix guide
- DLV-070ESP webhook for bounces not processedFix guide
- DLV-066ESP monthly sending quota exhaustedFix guide