Cancellation fee

Hey all,

I’m interested is there a way to create an early cancellation fee?

For example,

A user signs up for a 6 month services billed monthly and if they cancel before they’d get charged a certain amount based on the service membership costor a fixed fee.