Mail with gift card code is not received on purchase of gift card Magento

Please make sure that the value of “Generate Gift Card Account when Order Item is”  is set to “Ordered” . If its is set to  “invoiced” , the mail will be sent at the time of invoice generation .

Go to  System > Configuration > Sales > Giftcard