Diet could potentially influence the risk of biliary tract cancer directly or indirectly. Adherence to the dietary patterns was inversely associated with biliary tract cancer. The inverse associations were observed in both women and men. Dietary advice to consume healthy diets may reduce the risk of biliary tract cancer.