An exact exchange-correlation energy density is constructed using only
knowledge of the density dependence of the exchange-correlation energ
y functional, E-XC. The energy density does not depend on the choice o
f origin, and allows direct comparison between any functional approxim
ation and the exact quantity. The asymptotic behavior of this energy d
ensity contains the exact ionization potential. The relative performan
ce of approximation energy functionals is reflected in this energy den
sity, i.e., the local approximation is moderately accurate, generalize
d gradient approximations work better, while hybrids with exact exchan
ge work best. The intershell spike in atoms is highlighted in this ene
rgy density. The energy density can also be calculated for solids, and
has implications for many areas of density-functional theory. (C) 199
8 American Institute of Physics. [S0021-9606(98)30243-3].