As painful as it might look, updating or reinstalling Bluetooth drivers is the most recommended way to fix the frequent disconnection issue. Look for Bluetooth Power Management settings under Device ...
Does your Bluetooth keep turning off? Follow these suggestions to stop Bluetooth from automatically turning off in Windows 11/10: Disable Bluetooth power management Run Bluetooth Troubleshooter ...
I am assuming here that both the devices are paired. You can confirm that by going to Settings > Devices > Bluetooth. You can then follow the tips mentioned below if the Bluetooth speaker is connected ...