Energy conservation on mobile devices is now more important than ever due to the increasing benefits that smartphones and tablets provide to our daily life. However, most existing power management approaches either focus narrowly on a particular sub-system of the mobile device such as the sensor system, the LCD display, or the communication system, or use heuristic approaches to maximize energy efficiency at the cost of user experience. In this paper, we present Boe, a context-aware global power management scheme for mobile devices Balancing battery outage and user experience. To meet the mobile device's expected battery life while sacrificing end user experience as little as possible. Boe takes into account the users' phone usage patterns and activities to dynamically adjust the device's global power management policy to minimize outage time and maximize user experience. We demonstrate our proposed technique by controlling display brightness level and GPS sampling rate on smartphones. We evaluate our approach through real world smartphone data from 10 users over two months. Compared to the best fixed user experience policies, we show that: (i) Boe eliminates all frustrating battery outage events for light, moderate, and heavy phone users, and (ii) Boe improves user experience by 20% for light users, maintains the same user experience for moderate users, and degrades user experience by 23% for heavy smartphone users.