Adaptive thermogenesis is an energy-demanding process that is mediated by cold-activated beige and brown adipocytes, and it entails increased uptake of carbohydrates, as well as lipoprotein-derived triglycerides and cholesterol, into these thermogenic cells. Here we report that cold exposure in mice triggers a metabolic program that orchestrates lipoprotein processing in brown adipose tissue (BAT) and hepatic conversion of cholesterol to bile acids via the alternative synthesis pathway. This process is dependent on hepatic induction of cytochrome P450, family 7, subfamily b, polypeptide 1 (CYP7B1) and results in increased plasma levels, as well as fecal excretion, of bile acids that is accompanied by distinct changes in gut microbiota and increased heat production. Genetic and pharmacological interventions that targeted the synthesis and biliary excretion of bile acids prevented the rise in fecal bile acid excretion, changed the bacterial composition of the gut and modulated thermogenic responses. These results identify bile acids as important metabolic effectors under conditions of sustained BAT activation and highlight the relevance of cholesterol metabolism by the host for diet-induced changes of the gut microbiota and energy metabolism.