Unit content
Temperature dependence of equilibrium constants and the van 't Hoff equation
Because an equilibrium constant is connected to standard Gibbs free energy by
$$\Delta G^\circ=-RT\ln K,$$
changing temperature generally changes the value of $K$.
If the standard reaction enthalpy $\Delta H^\circ$ is approximately constant over a temperature interval, the integrated van 't Hoff equation relates the equilibrium constants at two temperatures:
$$\boxed{\ln\frac{K_2}{K_1} =-\frac{\Delta H^\circ}{R} \left(\frac1{T_2}-\frac1{T_1}\right)}.$$
Temperatures must be absolute, and $\Delta H^\circ$ must use energy units consistent with $R$.
The sign immediately gives the qualitative trend.
For an endothermic reaction, $\Delta H^\circ>0$. Increasing temperature makes $K$ larger, so equilibrium becomes more product-favored.
For an exothermic reaction, $\Delta H^\circ<0$. Increasing temperature makes $K$ smaller, so equilibrium becomes less product-favored.
This is the quantitative thermodynamic basis for the temperature part of Le Châtelier's principle: unlike a concentration disturbance at fixed temperature, changing temperature changes the equilibrium constant itself.
Example
Suppose an endothermic reaction has
$$K_1=2.00$$
at
$$T_1=300,\mathrm K,$$
with
$$\Delta H^\circ=+40.0,\mathrm{kJ/mol}.$$
Estimate $K_2$ at $350,\mathrm K$, treating $\Delta H^\circ$ as constant. Using $\Delta H^\circ=4.00\times10^4,\mathrm{J/mol}$,
$$\ln\frac{K_2}{2.00} =-\frac{4.00\times10^4}{8.314} \left(\frac1{350}-\frac1{300}\right) \approx2.29.$$
Thus
$$\frac{K_2}{2.00}=e^{2.29}\approx9.87,$$
so
$$K_2\approx19.7.$$
Raising the temperature strongly increases the product-favored equilibrium for this endothermic reaction.
The integrated equation is an approximation when $\Delta H^\circ$ changes appreciably with temperature. A more detailed treatment accounts for heat-capacity effects rather than treating reaction enthalpy as constant.