It is common for the first or second degree of various cohomologies to classify extensions of various sorts. Here are some examples of what I mean:

1) Derived functor of hom, $\text{Ext}^1_R(M, N)$. Let $R$ be a ring (not necessarily commutative, with a $1$). As is its namesake, $\text{Ext}^1_R (M, N)$ classifies extensions $0 \rightarrow N \rightarrow L \rightarrow M \rightarrow 0$ up to isomorphism. We can put an abelian group structure on this, the Baer sum.

2) Quillen cohomology, $\text{D}^1_{R} (A/B, M)$. Let $R$ be a commutative ring and let $A$ be an $R$-algebra. Let $B$ Be an $R$-algebra with a map into $A$ (so we have a sequence $R \rightarrow A \rightarrow B$). The first Andre-Quillen cohomology $D^1(A/B, M)$ is $\text{Exalcomm}(A/B, M)$, the set of $A$-algebra extensions $0 \rightarrow M \rightarrow C \rightarrow B \rightarrow 0$, where we set $a b = 0$ for $a, b \in M$.

In other cohomologies, $H^2$ classifies extensions:

3) Group cohomology, $H^2(G;M)$. Let $G$ be a group, and let $M$ be a $G$-module. $H^2(G;M)$ classifies extensions $0 \rightarrow M \rightarrow L \rightarrow G \rightarrow 0$ where $L$ is a $G$-module and $M$ has the same $G$-module structure as the one inherited from $L$.

4) Lie algebra cohomology, $H^2(\mathfrak{g};M)$. Let $R$ be a ring. Let $\mathfrak{g}$ be a Lie-algebra over $R$, and let $\mathfrak{a}$ be an abelian Lie-algebra over $R$. $H^2(\mathfrak{g}, \mathfrak{a})$ classifies central extensions $0 \rightarrow \mathfrak{a} \rightarrow \mathfrak{h} \rightarrow \mathfrak{g} \rightarrow 0$. See remark 4.7. here.

5) Hoschild cohomology, $H^2(R, M)$. Let $R$ be a commutative ring. The Hoschild cohomology module $H^2(R, M)$ classifies extensions $0 \rightarrow M \rightarrow S \rightarrow R \rightarrow 0$ where $ab = 0$ for $a, b \in M$. Note that Hoschild cohomology and Quillen cohomology are related; often $D^{n+1}(R, M) = H^n(R, M)$.

(1) and (2) are potentially different from (3) and (4), but there is the mentioned relationship between (2) and (5).

I am wondering if there is a (possibly categorical) unification of these theorems. Probably it would be easier to unify (1) and (2), and (3) and (4) separately- I can't say for sure there is a relationship between these pairs.

There is probably even a generalization to "extensions of length $n$" for many of these. For instance, $\text{Ext}^n(M, N)$ classifies exact sequences $0 \rightarrow N \rightarrow X_1 \rightarrow \cdots \rightarrow X_n \rightarrow M \rightarrow 0$ (See Weibel, $\textit{An Introduction to Homological Algebra}$, 3.4.6)

6more comments