In this work, we study the effects of random temperature fluctuations on the partition function of a quantum system by means of the replica method. This picture provides a conceptual model for a quantum nonequilibrium system, depicted as an ensemble of subsystems at different temperatures, randomly distributed with respect to a given mean value. We then assume the temperature displays stochastic fluctuations T=T0+δT with respect to its ensemble average value T0, with zero mean δT¯=0 and standard deviation δT2¯=Δ. By means of the replica method, we obtain the average grand canonical potential, leading to the equation of state and the corresponding excess pressure caused by these fluctuations with respect to the equilibrium system at a uniform temperature. Our findings reveal an increase in pressure as the system’s ensemble average temperature T0 rises, consistently exceeding the pressure observed in an equilibrium state. We applied our general formalism to three paradigmatic physical systems; the relativistic Fermi gas, the ideal gas of photons, and a gas of non-Abelian gauge fields (gluons) in the noninteracting limit. Finally, we explore the implications for the deconfinement transition in the context of the simple bag model, where we show that the critical temperature decreases.