{
  "name": "us-presidential-elections",
  "title": "US Presidential Elections 1789-2024: Electoral College and Popular Vote",
  "description": "Every US presidential election from 1789 to 2024: electoral votes by state and candidate, for President and for Vice President, from the National Archives (Office of the Federal Register) Electoral College results pages; the national popular vote by candidate as printed by official federal publications (Census Bureau, Historical Statistics of the United States, 1824-1968; Clerk of the House, 1972-1980; Federal Election Commission, 1984-2024); and one row per election with the winner, how he was chosen (Electoral College, or the House of Representatives in 1800 and 1824) and whether he also led the recorded popular vote.",
  "status": "structured",
  "version": "2026.11.0",
  "keywords": ["elections", "president", "electoral college", "popular vote", "united states"],
  "licenses": [
    {
      "name": "US-PD",
      "title": "Public domain: works of the US federal government (17 U.S.C. 105) and uncopyrightable vote counts. National Archives: \"Generally, materials produced by Federal agencies are in the public domain and may be reproduced without permission. Works of the U.S. Government that have been produced by the National Archives and Records Administration are in the public domain and may be copied and distributed without permission. These works are available for worldwide use and reuse under the terms of the Creative Commons CC0 1.0 Universal license.\"",
      "path": "https://www.archives.gov/global-pages/privacy.html"
    }
  ],
  "sources": [
    { "title": "National Archives, Office of the Federal Register: Electoral College Results, 1789-2024 (one page per election)", "path": "https://www.archives.gov/electoral-college/results" },
    { "title": "US Census Bureau, Historical Statistics of the United States, Colonial Times to 1970, Bicentennial Edition (1975), Part 2, Chapter Y, Series Y 79-83: Electoral and Popular Vote Cast for President, by Political Party, 1789 to 1968 (popular vote 1824-1968)", "path": "https://www2.census.gov/library/publications/1975/compendia/hist_stats_colonial-1970/hist_stats_colonial-1970p2-chY.pdf" },
    { "title": "Clerk of the US House of Representatives, Statistics of the Presidential and Congressional Election of November 7, 1972 (popular vote 1972)", "path": "https://clerk.house.gov/member_info/electionInfo/1972election.pdf" },
    { "title": "Clerk of the US House of Representatives, Statistics of the Presidential and Congressional Election of November 2, 1976 (popular vote 1976)", "path": "https://clerk.house.gov/member_info/electionInfo/1976election.pdf" },
    { "title": "Clerk of the US House of Representatives, Statistics of the Presidential and Congressional Election of November 4, 1980 (popular vote 1980)", "path": "https://clerk.house.gov/member_info/electionInfo/1980election.pdf" },
    { "title": "Federal Election Commission, Federal Elections reports 1984-2020 and Official 2024 Presidential General Election Results (popular vote 1984-2024)", "path": "https://www.fec.gov/introduction-campaign-finance/election-results-and-voting-information/" }
  ],
  "upkeep": { "mode": "frozen", "snapshot": "2026-11-29" },
  "resources": [
    {
      "path": "data/elections.csv",
      "name": "elections",
      "title": "One row per presidential election, 1789-2024: winner, how chosen, popular vote",
      "mediatype": "text/csv",
      "format": "csv",
      "encoding": "utf-8",
      "schema": {
        "fields": [
          { "name": "year", "type": "integer", "description": "Election year (the year the electors were chosen; 1789 for the first election, then every fourth year from 1792)." },
          { "name": "electoral_votes_cast", "type": "integer", "description": "Electoral votes for President in NARA's state table (after the corrections described in the README). Before 1804 each elector had two votes; the figure is the number of electors voting (votes cast / 2). 1868 includes Georgia's 9 contested votes." },
          { "name": "electoral_votes_needed", "type": "integer", "description": "Majority needed, as printed by NARA (Total/Majority)." },
          { "name": "president", "type": "string", "description": "Person elected President, named as on the NARA page." },
          { "name": "president_electoral_votes", "type": "integer", "description": "Electoral votes for President received by the person elected (before 1804: votes received under the two-vote system)." },
          { "name": "president_chosen_by", "type": "string", "description": "electoral_college (a majority of electoral votes), or house_of_representatives (contingent election: 1800, 1824).", "constraints": { "enum": ["electoral_college", "house_of_representatives"] } },
          { "name": "runner_up", "type": "string", "description": "Candidate with the most electoral votes for President after the winner (before 1804, excluding the person elected Vice President)." },
          { "name": "runner_up_electoral_votes", "type": "integer", "description": "Electoral votes of runner_up." },
          { "name": "vice_president", "type": "string", "description": "Person elected Vice President." },
          { "name": "vice_president_electoral_votes", "type": "integer", "description": "Electoral votes for Vice President received by the person elected (before 1804: votes under the two-vote system)." },
          { "name": "vice_president_chosen_by", "type": "string", "description": "electoral_college; electoral_college_runner_up (before 1804 under the original constitutional system, including Burr becoming Vice President after the House selected Jefferson from their 1800 tie); or senate (1836).", "constraints": { "enum": ["electoral_college", "electoral_college_runner_up", "senate"] } },
          { "name": "popular_vote_recorded", "type": "boolean", "description": "true if the sources give a national popular vote for this election (1824 onwards)." },
          { "name": "popular_vote_source", "type": "string", "description": "Publication the popular vote comes from." },
          { "name": "popular_vote_total", "type": "integer", "description": "Total popular vote as printed by the source (1972 onwards). Empty for 1824-1968: the Census table excludes unpledged tickets and minor candidates polling under 10,000 votes, and prints no national total." },
          { "name": "president_popular_votes", "type": "integer", "description": "Popular votes of the person elected President, from data/popular-vote.csv. For 1972 and 1980 this is his party's line only (see README)." },
          { "name": "president_popular_share", "type": "number", "description": "president_popular_votes as a percentage of popular_vote_total, 2 decimals. Empty where no total is printed." },
          { "name": "popular_vote_leader", "type": "string", "description": "Candidate (or party line, or 1836's combined Whig tickets) with the most popular votes in data/popular-vote.csv, ignoring write-ins, scattering and grouped 'other' columns." },
          { "name": "popular_vote_leader_votes", "type": "integer", "description": "Popular votes of popular_vote_leader." },
          { "name": "president_won_popular_vote", "type": "boolean", "description": "true if the person elected President is the popular_vote_leader; empty where no popular vote is recorded." },
          { "name": "president_popular_vote_margin", "type": "integer", "description": "President’s recorded popular votes minus those of the strongest other contender (margin_against). For 1972 and 1980, compares party lines rather than complete candidate totals; for 1836, the opponent is the combined Whig tickets. Negative when the President trailed." },
          { "name": "margin_against", "type": "string", "description": "The contender the margin is measured against." },
          { "name": "margin_share_points", "type": "number", "description": "president_popular_vote_margin as percentage points of popular_vote_total (1972 onwards)." },
          { "name": "notes", "type": "string", "description": "How the result was decided where unusual, source caveats (1960), and any state whose electoral votes were not all cast or not all shown by NARA." },
          { "name": "nara_notes", "type": "string", "description": "Notes from NARA’s election summary table, with HTML whitespace normalized." }
        ],
        "primaryKey": ["year"]
      }
    },
    {
      "path": "data/electoral-votes.csv",
      "name": "electoral-votes",
      "title": "Electoral votes by election, state, office and candidate, 1789-2024",
      "mediatype": "text/csv",
      "format": "csv",
      "encoding": "utf-8",
      "schema": {
        "fields": [
          { "name": "year", "type": "integer", "description": "Election year." },
          { "name": "state", "type": "string", "description": "State (or District of Columbia, from 1964) whose electors cast the votes." },
          { "name": "state_electors", "type": "integer", "description": "Value printed in NARA’s ‘Electoral Vote of Each State’ column; for 1789, its ‘Total electoral vote’ row. This is not consistently the number allocated or appointed: Nevada 1864 is printed as 2, although NARA notes that three votes were allocated and one elector did not vote." },
          { "name": "office", "type": "string", "description": "president, vice_president, or president_or_vice_president (1789-1800, when each elector cast two undifferentiated votes).", "constraints": { "enum": ["president", "vice_president", "president_or_vice_president"] } },
          { "name": "candidate", "type": "string", "description": "Person who received the votes, as named by NARA (column heading without 'of <state>', or the name in NARA's footnote for votes NARA groups as 'Others'). Names are not harmonised across years (e.g. 'Donald Trump' in 2016, 'Donald J. Trump' in 2020 and 2024)." },
          { "name": "electoral_votes", "type": "integer", "description": "Electoral votes cast by the state's electors for the candidate for this office. Only non-zero cells are included." },
          { "name": "note", "type": "string", "description": "NARA's footnote or unmarked state-table note for the state where it has one (faithless electors, split states, contested or uncounted votes), and any correction made here." }
        ],
        "primaryKey": ["year", "state", "office", "candidate"]
      }
    },
    {
      "path": "data/popular-vote.csv",
      "name": "popular-vote",
      "title": "National popular vote by candidate, 1824-2024, as printed by official sources",
      "mediatype": "text/csv",
      "format": "csv",
      "encoding": "utf-8",
      "schema": {
        "fields": [
          { "name": "year", "type": "integer", "description": "Election year." },
          { "name": "label", "type": "string", "description": "Row label: candidate if given, else party. Unique within a year." },
          { "name": "candidate", "type": "string", "description": "Candidate name from the source; for 1976, Carter and Ford are expanded using the same publication’s electoral-vote headings. Empty where the source reports a party line without a candidate." },
          { "name": "party", "type": "string", "description": "Party label(s) as printed by the source (2024: the FEC's party codes)." },
          { "name": "kind", "type": "string", "description": "candidate; party_line (1972 and 1980: the Clerk reports votes by party line, so a candidate's votes on other lines are not included); write_in; scattering; none_of_these (Nevada's 'None of these candidates'); other or other_parties (grouped columns in the Clerk's tables).", "constraints": { "enum": ["candidate", "party_line", "write_in", "scattering", "none_of_these", "other", "other_parties"] } },
          { "name": "popular_votes", "type": "integer", "description": "National popular votes as printed by the source." },
          { "name": "share_of_total", "type": "number", "description": "popular_votes as a percentage of the total printed by the source, 2 decimals (1972 onwards; empty for 1824-1968, where no total is printed)." },
          { "name": "source", "type": "string", "description": "Publication: Census Historical Statistics (1824-1968), Clerk of the House (1972-1980) or Federal Election Commission (1984-2024)." },
          { "name": "source_page", "type": "string", "description": "Printed page number of the table in the source (2024: page of the FEC results file)." },
          { "name": "note", "type": "string", "description": "Source footnotes and caveats for the row." }
        ],
        "primaryKey": ["year", "label"]
      }
    }
  ],
  "views": [
    {
      "name": "president-popular-vote-margin",
      "title": "Recorded popular-vote margin of the elected President, 1824–2024",
      "resources": ["elections"],
      "specType": "vega-lite",
      "spec": {
        "title": { "text": "Recorded popular-vote margin of the elected President, 1824–2024", "subtitle": "Votes, not shares. 1836 compares combined Whig tickets; 1960 follows Census’s published figures; 1972 and 1980 compare party lines, not complete candidate totals. No national total is printed before 1972." },
        "width": "container",
        "height": 340,
        "transform": [
          { "filter": "datum.popular_vote_recorded == true || datum.popular_vote_recorded == 'true'" },
          { "calculate": "datum.president_won_popular_vote == true || datum.president_won_popular_vote == 'true' ? 'Led the popular vote' : 'Trailed the popular vote'", "as": "outcome" }
        ],
        "mark": { "type": "bar" },
        "encoding": {
          "x": { "field": "year", "type": "ordinal", "axis": { "title": null, "labelAngle": -90 } },
          "y": { "field": "president_popular_vote_margin", "type": "quantitative", "axis": { "title": "Votes ahead of (or behind) the strongest rival" } },
          "color": { "field": "outcome", "type": "nominal", "title": null, "sort": ["Led the popular vote", "Trailed the popular vote"] },
          "tooltip": [
            { "field": "year", "type": "ordinal" },
            { "field": "president", "type": "nominal" },
            { "field": "margin_against", "type": "nominal", "title": "Against" },
            { "field": "president_popular_vote_margin", "type": "quantitative", "format": "," }
          ]
        }
      }
    }
  ]
}
