We incorporate nonlinear covers of quasisplit reductive groups into the Langlands program, defining an L-group associated to such a cover. This L-group is an extension of the absolute Galois group of a local or global field $F$ by a complex reductive group. The L-group depends on an extension of a quasisplit reductive $F$-group by $mathbf{K}_2$, a positive integer $n$ (the degree of the cover), an injective character $epsilon colon mu_n rightarrow {mathbb C}^times$, and a separable closure of $F$. Our L-group is consistent with previous work on covering groups, and its construction is contravariantly functorial for certain well-aligned homomorphisms. An appendix surveys torsors and gerbes on the etale site, as they are used in a crucial step in the construction.