Theorem 13.1.8 (Pointwise formula for right Kan extensions). Let \(u\colon A \to B\) be a functor between small categories and let \(F\colon A\catop \to C\) be a functor. Assume that, for every object \(b\) of \(B\), the functor \(F_{/b}\colon (A_{/b})\catop \to C\) admits a limit. Then \(F\) admits a right Kan extension \(u_*F\colon B\catop \to C\) along \(u\catop\), satisfying the pointwise formula \[ u_*F(b) \simeq \lim_{(A_{/b})\catop} F_{/b}. \] In particular, if \(C\) admits \((A_{/b})\catop\)-indexed limits for every object \(b\) of \(B\), then restriction admits a right adjoint \[ u_*\colon \Fun(A\catop,C) \to \Fun(B\catop,C). \]
Proof
Choose a universe so that \(C\) is small. The Yoneda embedding induces fully faithful functors \[ h_C\colon \Fun(B\catop,C) \to \Fun(B\catop,\PSh(C)) \simeq \Fun(C\catop,\PSh(B)), \] and similarly for \(B\) replaced by \(A\). The induced restriction functor \(u^*\colon \Fun(C\catop,\PSh(B)) \to \Fun(C\catop,\PSh(A))\) admits a right adjoint \[ u_*\colon \Fun(C\catop,\PSh(A)) \to \Fun(C\catop,\PSh(B)), \] For a functor \(F\colon A\catop \to C\) and an object \(b\) of \(B\), the anima-valued pointwise formula gives \[ u_*(h_C(F))(b) = \lim_{(a,s) : (A_{/b})\catop} h_C(F(a)) \simeq h_C(\lim_{(A_{/b})\catop} F(a)), \] where the final equivalence follows from the universal property of the limit in \(C\). Thus \(u_*(h_C(F))\) is pointwise representable and therefore lies in the essential image of \[ h_C\colon \Fun(B\catop,C) \longrightarrow \Fun(B\catop,\PSh(C)) \] by Corollary 12.3.17. Denote its unique preimage by \(u_*F\). For \(G\colon B\catop \to C\), full faithfulness of the Yoneda embedding and the ambient adjunction give natural equivalences \begin{align*} \Hom_{\Fun(B\catop,C)}(G,u_*F) &\simeq \Hom_{\Fun(B\catop,\PSh(C))}(h_C(G),u_*h_C(F)) \\ &\simeq \Hom_{\Fun(A\catop,\PSh(C))}(u^*h_C(G),h_C(F)) \\ &\simeq \Hom_{\Fun(A\catop,C)}(u^*G,F). \end{align*} This proves the universal property of the right Kan extension and the asserted pointwise formula. If the required limits exist for every functor \(F\colon A\catop \to C\), the pointwise criterion for adjunctions from Proposition 6.2.3 shows that these right Kan extensions assemble into a right adjoint to restriction.