Whether or not you have to pay back an ACH credit depends on the specific circumstances of the transaction.
If the ACH credit was the result of a mistake or error, such as a duplicate payment, then you would likely need to return the funds to the sender.
This could be done by initiating an ACH debit, which is a reversal of the original credit. If the ACH credit was the result of an intentional payment, such as a direct deposit of payroll, then the credit would be considered a legitimate transaction and the funds would be considered yours to keep.