Given two parallel morphisms f, g: A → B, an equalizer is an object E with a morphism e: E → A such that f∘e = g∘e, universal among all such objects: any h: C → A with f∘h = g∘h factors uniquely through e. The coequalizer is the dual: a quotient object that forces f and g to become equal. In Set, equalizers are subsets {a ∈ A | f(a) = g(a)} and coequalizers are quotient sets by the equivalence relation generated by f(a) ~ g(a). Kernels and cokernels in abelian categories are special cases.
Construct equalizers and coequalizers explicitly in Set and in Ab, verifying the universal properties in each case. Recognize that the kernel of a group homomorphism φ: G → H is the equalizer of φ and the zero morphism.
You already know what a universal property is: it defines an object not by internal structure but by how it relates to everything else in the category — the "best solution" to a mapping problem, unique up to unique isomorphism. Equalizers and coequalizers apply this idea to a very specific situation: two parallel morphisms f, g: A → B that you want to force into agreement. The equalizer solves "where do f and g already agree?" and the coequalizer solves "how do we make f and g agree by identifying things?"
In Set, the picture is completely concrete. Given two functions f, g: A → B, their equalizer is the subset E = {a ∈ A | f(a) = g(a)} together with the inclusion map e: E → A. The set E is exactly those elements of A where f and g give the same answer. The universal property says: if you have any other set C with a function h: C → A such that f∘h = g∘h (meaning h only picks elements where f and g agree), then h factors uniquely through E — you can route h through e. In abstract terms, E is the largest subobject of A on which f and g coincide. In many algebraic categories (groups, rings, modules), the equalizer of two homomorphisms φ, ψ: A → B is the subobject {a ∈ A | φ(a) = ψ(a)}, which is a genuine sub-algebra closed under the operations.
The coequalizer is the dual construction, and in Set it is a quotient set. Given f, g: A → B, the coequalizer is the set Q = B / ~ where ~ is the equivalence relation generated by declaring f(a) ~ g(a) for all a ∈ A. The coequalizer map q: B → Q sends each element of B to its equivalence class. The universal property says: if C is any set with a function k: B → C such that k∘f = k∘g (meaning k treats f(a) and g(a) as equal), then k factors uniquely through Q. In other words, Q is the *smallest* quotient of B in which f and g become equal after composition with the quotient map.
The connection to kernels and cokernels is worth making explicit. If φ: A → B is a group homomorphism, its kernel ker(φ) is the equalizer of φ and the zero morphism 0: A → B (both map A → B, and they agree exactly on elements that φ sends to the identity). The cokernel coker(φ) is the coequalizer of φ and 0: A → B — it is the quotient B / im(φ) that forces the image of φ to become the identity. This is why equalizers and coequalizers are foundational in abelian categories: kernels and cokernels (which you need to define exact sequences and homology) are simply the special cases where one of the two parallel morphisms is the zero map. Mastering equalizers and coequalizers in Set and Ab gives you the concrete intuition that carries directly into limits, colimits, and the rest of categorical algebra.