First we explain how to compute the higher direct images. Choose an injective resolution $\mathcal{F} \to \mathcal{I}^\bullet$. Then $R^if_*\mathcal{F}$ is the $i$th cohomology sheaf of the complex $f_*\mathcal{I}^\bullet$. Hence $R^if_*\mathcal{F}$ is the sheaf associated to the presheaf which associates to an object $U/S$ of $(\Sch/S)_\tau$ the module \begin{align*} \frac{\Ker(f_*\mathcal{I}^i(U) \to f_*\mathcal{I}^{i + 1}(U))} {\Im(f_*\mathcal{I}^{i - 1}(U) \to f_*\mathcal{I}^i(U))} & = \frac{\Ker(\mathcal{I}^i(U \times_S T) \to \mathcal{I}^{i + 1}(U \times_S T))} {\Im(\mathcal{I}^{i - 1}(U \times_S T) \to \mathcal{I}^i(U \times_S T))} \\ & = H^i(U \times_S T, \mathcal{F}) \\ & = H^i((\Sch/U \times_S T)_\tau, \mathcal{F}|_{(\Sch/U \times_S T)_\tau}) \\ & = H^i(U \times_S T, \mathcal{F}|_{(U \times_S T)_{Zar}}) \end{align*} The first equality by Topologies, Lemma \ref{topologies-lemma-morphism-big-fppf} (and its analogues for other topologies), the second equality by definition of cohomology of $\mathcal{F}$ over an object of $(\Sch/T)_\tau$, the third equality by Cohomology on Sites, Lemma \ref{sites-cohomology-lemma-cohomology-of-open}, and the last equality by Lemma \ref{lemma-same-cohomology-adequate}. Thus by Lemma \ref{lemma-sheafification-adequate} it suffices to prove the claim stated in the following paragraph. \medskip\noindent Let $A$ be a ring. Let $T$ be a scheme quasi-compact and quasi-separated over $A$. Let $\mathcal{F}$ be an adequate $\mathcal{O}_T$-module on $(\Sch/T)_\tau$. For an $A$-algebra $B$ set $T_B = T \times_{\Spec(A)} \Spec(B)$ and denote $\mathcal{F}_B = \mathcal{F}|_{(T_B)_{Zar}}$ the restriction of $\mathcal{F}$ to the small Zariski site of $T_B$. (Recall that this is a ``usual'' quasi-coherent sheaf on the scheme $T_B$, see Lemma \ref{lemma-same-cohomology-adequate}.) Claim: The functor $$ B \longmapsto H^q(T_B, \mathcal{F}_B) $$ is adequate. We will prove the lemma by the usual procedure of cutting $T$ into pieces. \medskip\noindent Case I: $T$ is affine. In this case the schemes $T_B$ are all affine and $H^q(T_B, \mathcal{F}_B) = 0$ for all $q \geq 1$. The functor $B \mapsto H^0(T_B, \mathcal{F}_B)$ is adequate by Lemma \ref{lemma-pushforward-adequate}. \medskip\noindent Case II: $T$ is separated. Let $n$ be the minimal number of affines needed to cover $T$. We argue by induction on $n$. The base case is Case I. Choose an affine open covering $T = V_1 \cup \ldots \cup V_n$. Set $V = V_1 \cup \ldots \cup V_{n - 1}$ and $U = V_n$. Observe that $$ U \cap V = (V_1 \cap V_n) \cup \ldots \cup (V_{n - 1} \cap V_n) $$ is also a union of $n - 1$ affine opens as $T$ is separated, see Schemes, Lemma \ref{schemes-lemma-characterize-separated}. Note that for each $B$ the base changes $U_B$, $V_B$ and $(U \cap V)_B = U_B \cap V_B$ behave in the same way. Hence we see that for each $B$ we have a long exact sequence $$ 0 \to H^0(T_B, \mathcal{F}_B) \to H^0(U_B, \mathcal{F}_B) \oplus H^0(V_B, \mathcal{F}_B) \to H^0((U \cap V)_B, \mathcal{F}_B) \to H^1(T_B, \mathcal{F}_B) \to \ldots $$ functorial in $B$, see Cohomology, Lemma \ref{cohomology-lemma-mayer-vietoris}. By induction hypothesis the functors $B \mapsto H^q(U_B, \mathcal{F}_B)$, $B \mapsto H^q(V_B, \mathcal{F}_B)$, and $B \mapsto H^q((U \cap V)_B, \mathcal{F}_B)$ are adequate. Using Lemmas \ref{lemma-kernel-adequate} and \ref{lemma-cokernel-adequate} we see that our functor $B \mapsto H^q(T_B, \mathcal{F}_B)$ sits in the middle of a short exact sequence whose outer terms are adequate. Thus the claim follows from Lemma \ref{lemma-extension-adequate}. \medskip\noindent Case III: General quasi-compact and quasi-separated case. The proof is again by induction on the number $n$ of affines needed to cover $T$. The base case $n = 1$ is Case I. Choose an affine open covering $T = V_1 \cup \ldots \cup V_n$. Set $V = V_1 \cup \ldots \cup V_{n - 1}$ and $U = V_n$. Note that since $T$ is quasi-separated $U \cap V$ is a quasi-compact open of an affine scheme, hence Case II applies to it. The rest of the argument proceeds in exactly the same manner as in the paragraph above and is omitted.