Check to determine if your JBL speaker’s battery is charged if it keeps turning off on its own. It’s conceivable that the charging cable or charging port has been broken, preventing the device from getting power when plugged in. To see if the problem is resolved, try various cables.