Direct observations of sunspot numbers are available for the past four centuries, but longer time series are required, for example, for the identification of a possible solar influence on climate and for testing models of the solar dynamo. Here we report a reconstruction of the sunspot number covering the past 11,400 years, based on dendrochronologically dated radiocarbon concentrations. We combine physics-based models for each of the processes connecting the radiocarbon concentration with sunspot number. According to our reconstruction, the level of solar activity during the past 70 years is exceptional, and the previous period of equally high activity occurred more than 8,000 years ago. We find that during the past 11,400 years the Sun spent only of the order of 10% of the time at a similarly high level of magnetic activity and almost all of the earlier high-activity periods were shorter than the present episode. Although the rarity of the current episode of high average sunspot numbers may indicate that the Sun has contributed to the unusual climate change during the twentieth century, we point out that solar variability is unlikely to have been the dominant cause of the strong warming during the past three decades.