With the U.S. election just weeks away, NASA has explained how astronauts vote in space.

The space agency has a motto of “Vote while you float” for astronauts.

“Like other forms of absentee voting, voting from space starts with a Federal Postcard Application, or FPCA,” NASA says on its website. “It’s the same form military members and their families fill out while serving outside of the U.S. By completing it ahead of their launch, space station crew members signal their intent to participate in an election from space.”

NASA notes that because astronauts move to Houston for their training, most opt to vote as Texas residents. “Of course, NASA’s astronauts come from all over, so those wishing to vote as residents of their home states can work with their counties to make special arrangements to vote from space,” it adds.

VOTING IN ORBIT: NASA ASTRONAUT CASTS BALLOT FROM INTERNATIONAL SPACE STATION

Once the FCPA is approved, the county clerk who manages elections in the astronaut’s home county sends a test ballot to a team at NASA’s Johnson Space Center, according to NASA. A space station test computer is then used to test whether it can be filled out and sent back to the county clerk.

An American flag in one of the windows of the International Space Station's cupola

An American flag in one of the windows of the International Space Station's cupola (NASA)

“After a successful test, a secure electronic ballot generated by the Clerk’s office of Harris County and surrounding counties in Texas, is uplinked by Johnson’s Mission Control Center to the voting crew member,” NASA says. “An e-mail with crew member-specific credentials is sent from the County Clerk to the astronaut. These credentials allow the crew member to access the secure ballot.”

“The astronaut will then cast their vote, and the secure, completed ballot is downlinked and delivered back to the County Clerk’s Office by e-mail to be officially recorded,” NASA adds. “The clerk has their own password to ensure they are the only one who can open the ballot. It’s a quick process, and the astronaut must be sure to submit it by 7 p.m. local time on Election Day if voting as a Texas resident.”

In 2016, NASA astronaut Shane Kimbrough, who at the time was the only American off the planet, voted in the presidential election from the International Space Station.

NASA ASTRONAUT, RUSSIAN COSMONAUTS WOKEN TO FIND SPACE STATION LEAK

NASA explained that the system was first employed in 1997 for former astronaut David Wolf when he was flying a long-duration mission on the old Russian space station Mir. Because Wolf’s mission spanned Election Day the process was set up to enable him to vote in space.

In 2020, more NASA astronauts will cast their votes in space. Kate Rubins, for example, is scheduled to launch to the orbiting space lab on Oct. 14 aboard a Russian Soyuz spacecraft from Baikonur Cosmodrome in Kazakhstan and will vote in space for the second time. Rubins also voted in space four years ago during a 115-day stint on the International Space Station. She voted prior to her return to Earth on Oct. 30, 2016.

Three more astronauts -- Mike Hopkins, Victor Glover and Shannon Walker -- are also set to launch to the space station from NASA’s Kennedy Space Center aboard a SpaceX Crew Dragon spacecraft on Oct. 31. They will be joined on the mission by Japanese Space Agency (JAXA) astronaut Soichi Noguchi.

Like Rubins, Hopkins, Glover and Walker are set to cast their ballots in space, according to NASA.

CLICK HERE TO GET THE FOX NEWS APP

NASA astronaut and Space Station Commander Chris Cassidy is scheduled to return to Earth on Oct. 21, Space.com reports. Cassidy, a U.S. Navy captain who spent 11 years as a member of the Navy SEALs, launched to the orbiting space lab on April 9, 2020.

The Associated Press contributed to this article. Follow James Rogers on Twitter @jamesjrogers