The process depends on the provider that billed you. A refund is not guaranteed and depends on the provider’s rules and your purchase.
App Store Go to https://reportaproblem.apple.com and sign in with the Apple Account used for the purchase. Choose the refund request option, select the relevant purchase, and follow Apple’s instructions.
Google Play Open Google’s refund guidance at https://support.google.com/googleplay/answer/2479637?hl=en and follow the process available for your purchase. Use the Google Account that made the purchase. Google’s instructions may direct you to the developer depending on your circumstances.
If you cannot identify the provider, check your receipt first. If you also want to stop future renewal, cancel the subscription separately.