The clerk to whom the counted and uncounted ballots are delivered shall, without breaking the seal, deposit them in a secure place in his office, where they shall be kept for the time required by this section. He shall not allow the ballots to be inspected except (i) by an authorized representative of the State Board or by the electoral board at the direction of the State Board to ensure the accuracy of the returns or the purity of the election, (ii) by the officers of election, and then only at the direction of the electoral board in accordance with § 24.2-672 when the provisions of § 24.2-662 have not been followed, (iii) on the order of a court before which there is pending a proceeding for a contest or recount under Chapter 8 (§ 24.2-800 et seq.) of this title or before whom there is then pending a proceeding in which the ballots are necessary for use in evidence, or (iv) for the purpose of conducting a risk-limiting audit pursuant to § 24.2-671.2. In the event that ballots are inspected under clause (i), (ii), or (iv) of this paragraph, each political party and each independent candidate on the ballot, or each primary candidate, shall be entitled to have a representative present during such inspection. The representatives and observers lawfully present shall be prohibited from interfering with the officers of election in any way. The State Board or local electoral board shall provide such parties and candidates reasonable advance notice of the inspection.
After the counted ballots for a federal election have remained in the clerk's office for two years, if no election contest or other proceeding is pending in which such ballots may be needed as evidence, the clerk shall destroy such ballots. After the counted ballots for any other election have remained in the clerk's office for one year, if no election contest or other proceeding is pending in which such ballots may be needed as evidence, the clerk shall destroy such ballots. After the unused ballots have remained in the clerk's office and the time has expired for initiating a recount, contest, or other proceeding in which such ballots may be needed as evidence and no such contest or proceeding is pending, the clerk may then destroy the unused ballots other than punchcard ballots, which shall be returned to the electoral board.
Va. Code § 24.2-669