Thomas Hofeller preached secrecy as he remapped American politics from the shadows. The Republican Party operative, known as the master of the modern gerrymander, trained other G.O.P. operatives and legislators nationwide to secure their computer networks, guard access to their maps, and never send e-mails that they didn’t want to see published by the news media. In training sessions for state legislators and junior line drawers, he used a PowerPoint presentation that urged them to “avoid recklessness” and “always be discreet,” and warned that “emails are the tool of the devil.”

Hofeller did not follow his own advice. Before his death, in August, 2018, he saved at least seventy thousand files and several years of e-mails. A review of those records and e-mails—which were recently obtained first by The New Yorker—raises new questions about whether Hofeller unconstitutionally used race data to draw North Carolina’s congressional districts, in 2016. They also suggest that Hofeller was deeply involved in G.O.P. mapmaking nationwide, and include new trails for more potential lawsuits challenging Hofeller’s work, similar to the one on Wednesday which led to the overturning of his state legislative maps in North Carolina.

Hofeller’s files include dozens of intensely detailed studies of North Carolina college students, broken down by race and cross-referenced against the state driver’s-license files to determine whether these students likely possessed the proper I.D. to vote. The studies are dated 2014 and 2015, the years before Hofeller helped Republicans in the state redraw its congressional districts in ways that voting-rights groups said discriminated on the basis of race. North Carolina Republicans said that the maps discriminated based on partisanship but not race. Hofeller’s hard drive also retained a map of North Carolina’s 2017 state judicial gerrymander, with an overlay of the black voting-age population by district, suggesting that these maps—which are currently at the center of a protracted legal battle—might also be a racial gerrymander.

Other files provide new details about Hofeller’s work for Republicans across the country. Hofeller collected data on the citizen voting-age population in North Carolina, Texas, and Arizona, among other states, as far back as 2011. Hofeller was part of a Republican effort to add a citizenship question to the census, which would have allowed political parties to obtain more precise citizenship data ahead of the 2020 redistricting cycle. State legislative lines could then have been drawn based on the number of citizen voters, which Hofeller believed would make it easier to pack Democrats and minorities into fewer districts, giving an advantage to Republicans.

Other documents show that Hofeller was hired by a Massachusetts Republican who sought to use the Voting Rights Act provision for majority/minority seats to draw a single district containing all of Boston, so that Republicans could make inroads into an otherwise entirely Democratic congressional delegation. Hofeller drew several sets of maps, but the effort went nowhere. Additional files document his work in Mississippi, Alabama, and Virginia, among other states.

E-mails also connect Hofeller to redistricting efforts in Florida. Top Republican officials in the state have denied that they played any official role in drawing the state’s legislative and congressional districts in 2011. A 2010 state constitutional amendment barred partisan gerrymandering in Florida. E-mails show that Hofeller communicated with and visited top G.O.P. political operatives in Florida in 2011. The operatives helped organize or draw state legislative and congressional maps that matched the districts that were later enacted. The operatives insisted, at a trial, that drawing the maps was only a hobby. A Florida judge found that argument unconvincing, concluding that the G.O.P. conducted a stealth redistricting operation that snuck partisan maps into the public process and made a “mockery” of the state’s constitutional amendments.

The files mostly pertain to Hofeller’s work in North Carolina, where he drew—and defended in court—the state’s legislative and congressional maps multiple times, after judges ruled them to be either unconstitutionally partisan or racial gerrymanders. The congressional lines that he helped draw in 2016 were struck down by a federal court as a partisan gerrymander; that decision was vacated this past June, in a 5–4 ruling by the U.S. Supreme Court.

Perhaps one of the clearest and ugliest gerrymanders in North Carolina—or in the entire nation—is the congressional-district line that cuts in half the nation’s largest historically black college, North Carolina A&T State University, in Greensboro. The district line divided this majority minority campus—and the city—so precisely that it all but guarantees it will be represented in Congress by two Republicans for years to come. North Carolina Republicans have long denied that this line, between the state’s Sixth and Thirteenth Congressional Districts, was intentionally drawn to dilute black voting power, which would be a violation of the constitutional prohibition against racial gerrymandering.

A map of Greensboro shows precincts color-coded by race and age.

Hofeller’s files, though, show that he created giant databases that detailed the racial makeup, voting patterns, and residence halls of more than a thousand North Carolina A&T students. He also collected similar data that tracked the race, voting patterns, and addresses of tens of thousands of other North Carolina college students. Some spreadsheets have more than fifty different fields with precise racial, gender, and geographic details on thousands of college voters.

A spreadsheet named “NC College Voters for ZIP ID” contains voter data for more than 23,100 North Carolina university students, including thousands in Greensboro. The detail for the North Carolina A&T students is precise: students are sorted by residence hall. That means that Hofeller knew which A&T students lived in Aggie Village, on the north side of campus, and which resided in Morrow or Vanstory Halls, on the south side—along with a detailed racial breakdown and information about their voting status. As Hofeller sought to create two reliably Republican congressional districts, his computer contained information on the precise voting tendencies of one of the largest concentrations of black voters in the area.

And if Hofeller cross-referenced that spreadsheet against another included on his hard drive, this one saved as “80 pct College Voters on Non-Match List”—which identified 5,429 North Carolina college students who appeared to lack the necessary I.D. required to cast a ballot at the time he drew the congressional maps—he could have crafted this line along Laurel Street, with even greater specificity about who would and would not be likely to vote.

North Carolina Republicans have admitted that the maps were intentionally drawn to lock in a partisan advantage, but not to harm minority groups. It is difficult to determine from a review of the files exactly how Hofeller used the data on race, but the documents serve as proof that he possessed the data and incorporated it into his decision-making.

His hard drive contained maps of Greensboro with the titles “Greensboro Master Race,” “Greensboro - Pct Blk - City Only VAP,” “Greensboro 45+ BVAP Compactness” and “Greensboro 50+ BVAP Compactness.” (VAP is short for “voting-age population,” and BVAP is an abbreviation for “black voting-age population.”) The “Greensboro Master Race” file contains a color-coded map that shows the city’s black population, age eighteen and older, by precinct.

Two files on Hofeller’s computer —“NC Juducial [sic] 2017 — stats” and “NC Judicial 2017 — Map”—break down the state’s eleven judiciary districts with race data. A PDF of a spreadsheet file shows that mapmakers constructed a file with partisan and racial information, including the percentage of Republican voters in each district, but also a column labelled “% 18+_AP_Black.” Those percentages are then overlaid on a color-coded map by district.