Abstract. The in general hard problem of computing weight distributions of linear codes is considered for the special class of algebraic-geometric codes, defined by Goppa in the early eighties. Known results restrict to codes from elliptic curves. We obtain results for curves of higher genus by expressing the weight distributions in terms of L-series. The results include general properties of weight distributions, a method to describe and compute weight distributions, and worked out examples for curves of genus two and three.