1) Externalities occur when the actions of individuals have unintended impacts on third parties. This can result in market failures when private costs/benefits differ from social costs/benefits.
2) For negative externalities like pollution, the private market equilibrium produces too much from a social perspective, since private costs are below social costs. Taxes can internalize these external costs.
3) For positive externalities like education, the private market equilibrium produces too little from a social perspective, since private benefits are below social benefits. Subsidies can internalize these external benefits.