Error - If the invoice was created offline, try creating an offline credit memo

I am getting above error when refunding shipping amount "online".

Can anybody please explain me why i am getting this error also in which case this error can appear ?

BTW - I am using custom script that refund shipment amount online.


  • any thoughts on this ?
    – devhs
    May 27, 2021 at 9:03
  • please add some more details like logs or screenshots as well as which payment method you are using
    – Waqar Ali
    May 27, 2021 at 9:21

1 Answer 1


The error you are facing, which means you have created invoice offline so there was no transaction for this invoice and that's why you are not allowed to refund online.

Online capture of depend on which payment gateway you are using. If you are using offline payment like COD, then invoice will be created offline and you have to refund offline for that invoice.


  • Thankyou ZealousWeb for answer
    – devhs
    May 27, 2021 at 12:05
  • Can you please upvote and approve?
    – ZealousWeb
    May 28, 2021 at 12:34

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