Dietary nutrients shape complex interactions between hosts and their commensal gut bacteria, further promoting flexibility in host-microbiota associations that can drive nutritional symbiosis. However, it remains less clear if diet-dependent host signaling mechanisms also influence these associations. Using Drosophila, we show here that nuclear factor κB (NF-κB)/Relish, an innate immune transcription factor emerging as a signaling node linking nutrient-immune-metabolic interactions, is vital to adapt gut microbiota species composition to host diet macronutrient composition. We find that Relish is required within midgut enterocytes to amplify host-Lactobacillus associations, an important bacterial mediator of nutritional symbiosis, and thus modulate microbiota composition in response to dietary adaptation. Relish limits diet-dependent transcriptional inducibility of the cap-dependent translation inhibitor 4E-BP/Thor to control microbiota composition. Furthermore, maintaining cap-dependent translation in response to dietary adaptation is critical to amplify host-Lactobacillus associations. These results highlight that NF-κB-dependent host signaling mechanisms, in coordination with host translation control, shape diet-microbiota interactions.