# Custom Date Conditions in Mautic Testing

**URL:** https://forum.mautic.org/t/custom-date-conditions-in-mautic-testing/27273
**Category:** Product Support
**Created:** [March 6, 2023, 6:04pm UTC](https://forum.mautic.org/t/custom-date-conditions-in-mautic-testing/27273 "2023-03-06T18:04:36Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![chrisjrocha](https://avatars.discourse-cdn.com/v4/letter/c/dbc845/32.png) [@chrisjrocha](https://forum.mautic.org/u/chrisjrocha)
#### Post date: [March 6, 2023, 6:04pm UTC](https://forum.mautic.org/t/custom-date-conditions-in-mautic-testing/27273/1 "2023-03-06T18:04:37Z")

</div>

Hello, I am trying to send an email based on a custom date condition. I am following this article here.

> **[How to Use Custom Date Conditions in a Campaign - Mautic](https://mautic.com/help/custom-date-conditions/)**
>
> As of the September 2017 update (Mautic 2.10), you can now create a condition in a campaign that allows you to set an action for any date relative to the value in a date field on contact record.

I want to send am email to a user who’s expiration expires in 2 days. Here is what the campaign looks like and the custom date condition…

![image](https://us1.discourse-cdn.com/flex020/uploads/mautic/original/2X/5/546c1ec720688064c12812dc7803ca61d695cfdb.png)

![image](https://us1.discourse-cdn.com/flex020/uploads/mautic/original/2X/9/9e4193abcebc5812e3e6ab7aca0ce85e3e107626.png)

To test this, I set the users expiration date to 2 days in the future and add them to the campaign. However, the campaign fails and does not send the email. I’m not sure what is wrong. Any suggestions?

Thanks

---

<div class="post-metadata">

### Author: ![asad786](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/asad786/32/8990_2.png) [@asad786](https://forum.mautic.org/u/asad786)
#### Post date: [March 14, 2023, 1:05pm UTC](https://forum.mautic.org/t/custom-date-conditions-in-mautic-testing/27273/2 "2023-03-14T13:05:13Z")

</div>

You can set the condition for current time, not for -2 days that is custom date, you can check if current date matches the expiration date, then test it via increase date of system 2 days after.
