June 19, 2024

Sort the mail-in ballot envelopes, or don’t?

How mail-in ballot envelopes are handled by local election officials can make a huge difference in the cost of recounts and can also affect the security of elections against one form of voting fraud.

Counties that count thousands or millions of mail-in (or dropbox) ballots can do it two ways:

Sort-then-scan:  Sort the ballot envelopes by precinct-number, using the voter information and signature on the outside of the envelope;  open the envelopes and unfold/flatten the paper ballots within; then scan a stack of all-the-same-precinct ballots.

Scan-then-sort:  Take a big batch of unsorted ballot envelopes from various precincts in the jurisdiction; open all the envelopes in the batch and unfold/flatten the paper ballots; then scan a stack of various-precinct ballots.  Because each ballot has its precinct-number printed on it as a barcode, the computers will be able to allocate the votes to the right precincts.

Mail-in ballot package in New Jersey. Voter marks opscan ballot, puts into inner envelope, signs inner envelope, puts into outer envelope, mails or puts into dropbox.

In each method, the voter’s name, address, voter-registration-number, and signature is on the envelope; before opening the envelope, look this up in the poll-book database, to check that the voter hasn’t already voted, and mark in the database that they have now voted.

Scan-then-sort has three problems: (1) opportunity for cheating (2) grossly expensive recounts (3) extra expense in ballot printing.

First problem with scan-then-sort: opportunity for cheating: a voter could try to cheat in an election by voting in a different precinct.  Suppose you live in the city of Townville, but you’d really rather vote in the mayoral election of Burgton (another town in the same county).  Or suppose your county is split between two Congressional districts: your district is a landslide, hardly worth voting in, but the other is a swing district and you’d rather vote there.  Just make a copy of the Burgton ballot, (illegitimately) vote in those contests, put it in your Townville envelope, and mail it in.  By the time any computer or person actually looks at your paper ballot, it will have been completely separated from your envelope.  (Don’t try to cheat this way, it’s illegal!)

I’ve talked to three experienced election administrators about this.  Two-and-a-half of them are sure this attack couldn’t work, because your fake copy of the Burgton ballot would be low-quality, or would be on the wrong kind of paper, and the election workers would notice that even as they’re opening the envelope.   I’m not so sure, especially in these days when everyone has access to high-resolution PDF printing. And I’ve talked to one person who says this was a large-scale practice where she once lived: operatives would raid the trash cans in apartment-complex mailrooms for unvoted ballots to use in exactly this way.

Election administrators also tell me, “there would be more ballots reported for Burgton than envelopes, and the discrepancy would be noticed.”  But even if it’s noticed, that doesn’t mean it can be corrected!  By the time the ballots have been separated from their identifying information, it’s too late; the only correction would be a do-over election.

On the other hand, this attack (totally illegal, don’t even think of doing it) would not succeed with the sort-then-scan method.  In that method, what you feed through the scanner is (supposed to be) a stack of all-one-precinct ballots, each encoded with its precinct-ID barcode.  Any ballot with the wrong precinct-ID will be detected by the scanner.  In fact, in well-organized election offices this is caught as soon as the envelope is opened; see my note below about Montgomery County, MD.

Second problem with scan-then-sort:  recounts.  Suppose a candidate for Mayor of Townville demands a recount of the mayor’s race, as entitled by state law.  Remember, an important purpose of a recount is to make sure the computers didn’t get anything wrong, so it’s important to look at the actual paper ballots.  Among the 1 million ballots in the whole county, how do you find the 30,000 paper ballots from the 60 precincts of the Townville?  With the sort-then-scan method, it’s easy:  there are 60 distinct and identifiable batches of ballots, easy to find in the county vault, and those are the ballots to recount.  But with scan-then-sort, those ballots will be scattered among all the batches, and it will be extremely expensive to find them. 

This recount problem is not merely hypothetical.  In 2020 in Los Angeles County, the City of Long Beach had a tax-rate referendum on which the voting machines reported 49,676 “yes” votes and 49,660 “no”—a 16-vote margin of victory.   A citizens’ group asked for a recount of the paper ballots in the City of Long Beach’s tax-rate referendum.  By California law they were entitled to a recount provided they paid for it; and according to the guidelines published by LA County this should have cost approximately $20,000 (about 20 cents per ballot to pay the 4-person teams that would tally and recount).  But the LA County election officials then told them that they’d first have to pay about $187,000 just to sort the 2.1 million LA County ballots and find the 100,000 Long Beach ballots within them—plus the cost of recounting them.   [see note below] In Los Angeles County, 54% of the ballots were mail-in ballots, the rest were vote-center ballots.  None of these had been physically sorted by precinct.  So, scan-then-sort raised the price of a recount by about a factor of 10.

In Hays County Texas, a candidate asking for a recount of a 2022 countywide District Attorney race had to pay about three times as much for a hand recount (about $30,000 instead of $10,000), because of the extra time it took for the recount teams just to sort each bag of ballots by precinct before starting the actual count.  Most of these ballots were cast in vote centers.  [see note below]

Third problem with scan-then-sort:  Most jurisdictions require election officials to account for every vote cast by the precinct in which the voter is registered.  With scan-then-sort, that requires every precinct to have its own ballot-style number printed (barcoded) onto the ballot.  This proliferation of ballot styles causes extra expense in printing, extra work in logic-and-accuracy testing, extra work in logistics.  In contrast, with sort-then-scan, many precincts can share the same ballot-style number, as long as they all have the same set of contests and candidates—because the voter information on the outside of the envelope is enough to sort by precinct.

Conclusion.  The Latin phrase from 1209, Caedite eos. Novit enim Dominus qui sunt eius”, roughly translated as “Kill them all and let God sort them out,” expresses pretty well the scan-then-sort method, which we could write in Latin as Numerate eos. Novit enim machina quo irent  (count them all, the computer knows where they go).   Either way, it was a bad idea in 1209 and it’s a bad idea now.

Fortunately, for mail-in ballots there’s a clear solution.  Some high-population counties use sorting equipment to sort ballot envelopes into batches by precinct, before opening them.  So the sort-then-scan method can be done in a cost-effective way, and in many jurisdictions that’s what they do.  In other jurisdictions they do sort-then-scan without even needing high-tech equipment.

But in LA County and in Hays County, many of the unsorted ballots were from in-person vote centers: each voter can use any vote center in the county, they are supplied with the appropriate ballot style (marked by precinct-number barcode), and the machines sort them out electronically.  With unsorted vote-center ballots, recounts are difficult, and I’m not sure what the best solution is.

Part 2: How to sort mail-in ballots


  • Long Beach, California:  The description above of recount costs comes from the Plaintiffs’ brief in Long Beach Reform Coalition v. Dean C. Logan, 2021.
  • Hays County, Texas:  The information about sorting and recount effort comes from an interview with Laura Nunn, who was employed by Hays County to work in one of the recount teams.  The “upwards of $40,000” referred to in the CBS News article included extra photocopying, requested by the candidate, that was not part of the recount proper.
  • Montgomery County, Maryland:  Montgomery County uses a high-speed envelope scanner/sorter to sort mail-in ballots before opening the envelopes.  My next article will describe how they do it.


  1. Joe Weinstein says

    Thanks all for your concerns. As a member of the Long Beach Reform Coalition (LBRC) Board of Directors, I can attest that our exec director, Ian Patton, works tirelessly and even miraculously against all odds for reasoned reform in muni and county government.

    You all want better run elections. So long as we are stuck with elections, so do I..

    But I have aged, and am tired with playing a nonsensical game against a constitutionally and legally mandated corrupt arrogant all-powerful house.

    Very simply, we don’t need expensive and contentious elections – let alone complex schemes to ‘reform’ them to be ‘fairer’- because we don’t need the officialdom which are thereby elected.(or ratified) – nor mass non-deliberative referenda. We don’t need to leave public policy decisions to an officialdom oligarchy – to the same few folks empowered to make decision after decision after decision for years at a time on a host of key public affairs. Nor do decisions need to be thrown to non-deliberative costly and contentious mass votes.

    The decisions can instead be done far less corruptly (recall Acton: ‘power tends to corrupt …’) and far more deliberatively by many short-term teams of randomly selected willing ordinary citizens who thereby do a manageable non-career bit of public service. Unlike today’s officialdom, these teams will be required to follow rules of rational deliberation (including: defining the problems/challenges to be solved, considering a spectrum of options, requiring and reviewing impact analyses for the options, providing a convincing rationale for their decisions as input to independent real-time veto-potent review by other teams; etc., etc.)

    The legally all-powerful decision oligarchy of high officialdom (in just about every USA jurisdiction) in fact violates my right – and yours – to be a full citizen and to participate equally – but at manageable expense in time and energy – in making deliberated public policy. The oligarchic republican officialdom not only is an affront to meaningful democracy but, worse, they are free to make decisions by utter whim (and often by anti-consensual clash of whims, arbitrarily ‘resolved’), without following any rules of reason.

    The system of policy decision-making is needlessly irrational and discriminatory. It’s time for our obsolete methods of public policy decision to join other arenas of enterprise – and actually be re-engineered (rather than continue to be religiously venerated decade after decade, century after century) to incorporate basic rationality as well as current opportunities and challenges.

    I don’t know about others, but my life is too short, and too full of other interesting projects, for me to get too involved in minor would-be ‘reforms’ which preserve the oligarchy and un-reason.

    THANKS for reading , HAPPY NEW YEAR 2024

  2. Linda Scholl says

    Long Beach CA voters are paying now a 10.5% sales tax for eternity now. The Measure A recount was requested because the Measure passed by only 16 votes. When you read the article above in the context of a tax increase that passed with 16 votes, you realize how important effective voting administration affects evrryone’s Pocketbook. Thank you for this article that provides insightful analysis.

    • Richard Michael 909-378-5401 says

      I tried to convince the Long Beach Reform Coalition executive director and board to file an election contest rather than do a recount. Historically, recounts almost never change the end result.

      After they ran into the unsorted ballots problem, I tried again. But they went with the law firm that represents Los Angeles Unified School District. The firm claimed it was a good case. Then they lost and the firm advised not to appeal, as it might set a bad precedent. So, now you have recountitis in every county in California.

      There was still time to file an election contest based on the unconstitutionality of the ballot label, containing many arguments in favor of the measure, which was printed and circulated using public monies — a big no-no according to the California Supreme Court in a line of cases, the most famous of which is Stanson v. Mott.

      Measure A read:
      “To maintain 911 emergency response services, police, fire, parks, improve water quality, repair streets, and maintain general services, shall a measure be adopted extending the City of Long Beach’s transactions and use (sales) tax beyond 2027, generating approximately $60 million annually, at a maximum rate of one cent (1%) per the measure until ended by voters, requiring a citizens’ advisory committee and annual independent audits, with all funds remaining in Long Beach?”

      With all those reasons to vote yes right on the ballot, the determined yet meager campaign against the measure didn’t have a chance.

      • It was not a viable legal option according to our attorneys at Strumwasser & Woocher, the state’s top election law firm.

  3. Paul Burke says

    Scanning withut sorting does have problems, as the article says. Let’s recognize some other problems with sort-then-scan.

    Mail ballots arrive and are processed in CA and some other states for about a month before, and 1-3 weeks after, election day, say at least 20 working days with a high volume of arriving mail. Sorting each day’s mail into 60 precincts means 20 x 60 = 1,200 piles. 600 precincts would mean 12,000 piles. Putting 60 or 600 separate batches through the scanners during each day & tracking the rejects (which will now include the wrong precinct as well as hard-to-read ballots) could have more errors than leaving them in fewer un-sorted batches.

    One alternative is to sort and report by style instead of precinct, but there can still be hundreds of styles in a big county.

    The simplest alternative is to let the requester of a recount use the computer file of ballot images to pull out the images to recount. They can be recounted by hand or by a better software system. AuditEngine has done exactly this analysis of overvotes and all votes more accurately than commercial systems. https://copswiki.org/w/pub/Common/M1970/Case%20Study%20Report%202020%20General%20Election.pdf . Recounting ballot images works just as well for vote-center ballots as it does for mailed envelopes.

    Yes, this doesn’t directly look at paper, and the scanner could have hacked the images. Hacked images have not yet been seen in the wild, while errors in tracking batches of ballots are seen all the time. Errors in storing paper ballots also happen often. Scanned ballot images are typically made before ballots go into storage, so images avoid storage problems. Storage problems do prevent accurate paper audits and paper recounts.

    Good existing audits (not in CA) can and do already check that images are accurate. When audits check that hand counts of paper ballots match election results, they show the images were not hacked, since hacked images would have different totals from hand counts of paper.

    • Paul Burke says

      Ray Lutz suggested in his weekly conference call today, an approach to sorting paper ballots for a recount which need not cost hundreds of thousands of dollars.

      Commercial scanners have the ability to set aside ballots based on decision rules, often called a reject tray. To pull out ballots for recount, the county can run unsorted voted ballots through scanners, using this ability to set aside desired ballot styles. Style is coded on each ballot. The reject tray will have the desired ballot styles, so the recount can go ahead.

      LA had 4,338,191 ballots in 2020. Vote center ballots (BMDs) had one sheet. Mailed ballots had 1 or more sheets, depending how many the voter sent back. An average of 2 sheets per ballot gives 8.7 million sheets.

      A 300 sheets/minute scanner, with 2 staff to load & unload the scanner in 15 seconds, can process 14,000 ballots/hour. It would take 600 scanner hours to run 8.7 million sheets through the scanners, to set aside the Long Beach ballots. With 2 staff per scanner, at $15/hour, this sorting would cost $18,000. A 150 sheets/minute scanner can handle 8,000 sheets/hour and staff cost would be $33,000. In smaller counties, costs would be far less.

      Sorting before scanning isn’t any cheaper, and can’t handle vote center ballots.

      Using ballot images is far cheaper than any of these sorting options, but sorting paper ballots is affordable with this approach.

      • Ian Patton says

        Hi Paul,

        I have too many thoughts on your comments, as the person who led this recount effort in LA County.

        The first thing I should say is how wonderful it would be if LA County Registrar Dean Logan cared about *any* of this.

        The main takeaway from our experience was that his office had commissioned a $300 million new voting system (VSAP) without putting any thought whatsoever into the auditability of elections using that new system. His interest only seemed to lie in doing the legally required random 1% hand tally audit after the election and to be done. When it came time to perform a recount, because we requested it as our right under state law, he threw up every obstacle imaginable to delay and increase costs, which he chose to burden us with (ultimately our unsuccessful lawsuit sought to force him to bear the costs of the new massive, ridiculous hand sorting process to sort through millions of ballots apparently required as a result of the fact that VSAP had no automated sorting process in its design).

        There were no policies or processes for conducting a recount with the new system and everything was figured out on the fly. We ended up doing a still very expensive attempt at trialing the digital ballot image option, the County having given us three options, all orders of magnitude more expensive than a recount under the old system (including about a quarter million dollar option, estimated, to sort out ballots by hand and do a full hand count). The digital ballot counting process turned out to be extreme slow and ineffective precisely because there had been no software developed for it. They did develop a means of viewing the ballot PDFs that was slightly better than opening and closing individual PDF files, but there were many glitches and problems.

        I certainly wish Logan was interested in a better auditing process, before even getting to the potential need for a recount. Risk limiting audits are, of course, much better than a straight 1% audit. But the problems don’t end there.

        There’s clearly something wrong with the *way* Logan is carrying out the 1% audit. While we only got through about 12k out of about 100k ballots for our city, during our attempted digital ballot recount (before the absurdly spiraling cost shut us down), we came across a number of anomalies. They were all consistent in that hand-marked vote by mail ballots with a tick on the other electoral option (a clear Yes and a tick or jot somewhere by the No, for this ballot measure) would lead to an overvote in the machine count, whereas voter intent was utterly clear to all human eyes. Yet Logan’s 1% audit (which hand tallied about 21,000 ballots) came out “perfect” with “zero variances”. Our recount variances were officially recorded and can still be downloaded from the County web site, with changed vote totals for several precincts. Those two outcomes in the same election strike me as statistically implausible if not impossible. I suspect Logan was having his staff intentionally use “computer judgment” rather than human judgment when they did the 1%. That sounds strange, but not only is it the only explanation but it’s also what they were trying to do initially during our recount until we told the staff (which had no written procedures) they weren’t following state law, and logic, in interpreting voter intent. Initially they even wanted us to save our human eyes voter intent of these anomalous ballots as “objections” for the Registrar himself to personally adjudicate at the end. We convinced them that that would still violate the purpose of a recount and the law, and they relented.

        Another issue with the 1% audit in CA is that it no longer requires at least one ballot from every precinct. To accommodate VSAP, the law was changed so that they only need to have at least one ballot from each “batch” (box full of random ballots from all over the county).

        Moving on from the automatic post-election audit, back to recounts, let me just say, you mentioned something that really blew my mind: Of course the enormous charge for sorting ballots (which we never believed we should’ve had to bear, with an estimated cost of over $180k just for 16 county workers to spend 16 full days sorting every last one of the 100k Long Beach ballots out of the 2.1 million ballots cast overall, this being the 2020 primary election, not the general) should never have been contemplated as a completely physical human task.

        I analogized it to a stone age process for what was supposed to be a space age new voting system. It was complete absurdity. And I’m sure I asked them if there was any other way at the time, but ballot sorting was just never designed into VSAP (with the clear intent that a physical hand recount would never occur, if avoidable) and hand sorting through millions of ballots by county workers was the only (false) option we were given (and, btw, given just barely a day before our recount was legally required to begin).

        But of course, like you say, the scanners themselves should’ve been able to handle this task!!!!!!!! Of course, there really should’ve been special sorting machines, that did nothing but sort, built into the overall cluster of devices comprising the VSAP design/system. But the scanners alone would’ve sufficed in a pinch (like the one we were in)!!

        At the time, we knew nothing about the technology, but we later investigated everything we could during our litigation. First of all, what you say about the reject tray alone would’ve/should’ve been sufficient to cut down on the human labor tremendously: Run all 2.1 million county ballots (which, btw, came out to 3.9 million sheets or ballot ‘cards’) through the machines once to pull out the Long Beach ballots. Then just run the Long Beach ballots through as many times as necessary to sort out the precincts. Now the tricky part there is of course the number of times you’d have to run them through to sort out the precincts with essentially just two trays.. the keeper pile and the reject tray pile….. except that of course these machines can do much better than that!

        Here are the scanning machines included in VSAP (of which they had 20 in the tabulation room when i observed it): https://www.ibml.com/wp-content/uploads/2019/11/2020-ImageTrac-Series-6400-Slick.pdf

        And what does it say about these machines?….
        “The power of the ImageTrac 6400 class scanners makes them perfectly suited for high-volume sorting applications such as:
        • Medical records scanning
        • Mortgage processing
        • Tax processing
        • Claims processing
        • Application processing
        • Lockbox processing
        • Back-file conversion
        • Service bureau/shared services processing
        • Digital mailroom”

        And options include: “• Up to 21 sort pockets”

        Unfortunately, I don’t have the mathematical skills to figure out the equation for the run time necessary to do a recursive bucket sort (only enough very old computer science knowledge to vaguely remember what that is) on 2.1 million ballots, consisting of 3.9 million cards, using 21 buckets, which, if you did it countywide would need to be sorted into about 3,600 separate precincts, or for just Long Beach, one sort run to get the city out of the county, then sorting into 186 separate precincts.

        But I have little doubt that these machines could be programed to do just that and enormously reduce the effort compared to pairs of hands sifting 100k ballots from 2.1 million ballots one-by-one and simultaneously sifting them into 186 separate piles for Long Beach precincts.

        Suffice to say, any way you slice it, we got screwed. There was NEVER any serious intention to figure this out, either during the 10 years of VSAP development, or in the days leading up to our recount. And the people of LA County to this day continue to have not only their right to recount election results effectively denied by intentional obtuseness and bureaucratic opposition but also their right to confidence in their election tabulation system overall denied.

        One other note. As far as the statement, “Putting 60 or 600 separate batches through the scanners during each day & tracking the rejects (which will now include the wrong precinct as well as hard-to-read ballots) could have more errors than leaving them in fewer un-sorted batches,” goes…. I really don’t understand that. What would be the source of errors created by pre-sorting the ballots and/or storing them that way? Is the idea just that ballots have a way of being more likely to ‘disappear’ the more times they’re dealt with? It seems to me that safeguarding the ballots while handling them is about the most basic logistical responsibility of the Registrar’s office and something which proper procedures and practices should be able to effectuate. And if the QR codes on the ballots are programmed properly, there shouldn’t be any danger of counting the same ballot twice (i.e. each ballot has a unique ballot ID).

        I really appreciate your interest in this, Paul, and hope to be able to continue getting your thoughts!

    • Jann Kurrasch says

      All of these are the reasons why we should have in-precinct voting with paper ballots. Make Election Day a national holiday; people who can’t be there in person can apply for an absentee ballot that is returned to their precinct; those who vote in person show ID to cast a ballot. Problem solved.

      • Julie Weiner says

        We are about to lose the right to vote on hand marked paper ballots in NYS. We need to pass VIVA NY (A5934a/S6169a). Know anyone in NYS? Please have them call Assembly Speaker Carl Heastie, 518-455-2585 and Senate Majority Leader Andrea Stewart Cousins , 518-455-2585, and urge them to prioritize voters’ right to verifiable elections over those of lobbyists and their friends working for voting machine vendors. Or just tell them you want to keep marking your ballot in your polling place with a pen. The legislature ends its session on Thursday – 6/8.