  The Wiener index of a (hyper)graph is calculated by summing up the distances
between all pairs of vertices. We determine the maximum possible Wiener index
of a connected $n$-vertex $k$-uniform hypergraph and characterize for every~$n$
all hypergraphs attaining the maximum Wiener index.
