Up to 16,000 Public and Commercial Services union (PCS) members will stage the walkout next Thursday, the day before the opening ceremony in London.
Staff across the Home Office – including the Border Agency, the Identity and Passport Service and Criminal Records Bureau – could take part.
Glasgow and Edinburgh airports are expected to be affected by the action, as many people arrive in the Scottish capital for the Edinburgh Festival. Chaos is predicted at Heathrow, the main arrivals hub for the Olympics.
The strike adds to the UK Government's growing woes over security in the run-up to the Olympics, with G4S's failure to fulfil its £280 million contract to provide 10,000 guards, forcing Westminster to use thousands of soldiers.
Home Secretary Theresa May put 1200 services personnel on stand-by yesterday, in addition to the 3500 already called up. But she was accused of misleading MPs over when she knew the private security firm was facing problems recruiting enough staff.
Politicians condemned the strike, which was called over job cuts and a cap on wage increases. Mrs May said the PCS's timing was "shameful".
Immigration minister Damien Green said: "This is absolutely the wrong way for any union leader to behave – to try and see 'what damage can I cause to the country? How and when can I cause most damage?'."
Prime Minister David Cameron, speaking at a press conference in Afghanistan, said: "I do not believe it will be right, I do not believe it will be justified."
Conservative MPs called for a minimum threshold for strike ballots, after the action was called on a turnout of just 20%, of which just over half voted for the action.
Labour leader Ed Miliband said workers "should not be striking during the Olympics".
But Labour MP John McDonnell said the Government had brought the dispute "on its own head" and that MPs had met ministers only three weeks ago to warn of the looming problem.
The PCS denied accusations it was using the ceremony to press its members' demands, saying it had repeatedly urged the Home Office to call off plans to cut 8500 jobs and cap a pay rise at 1%.
PCS general secretary Mark Serwotka said: "We're not holding anyone to ransom.
"This strike is an absolute last resort because everything else we have tried to get them in a room to negotiate these problems, they have refused."
As well as a one-day strike, a work-to-rule and overtime ban will be in place during the Olympics, which could also have a major effect on border controls.
The strike will coincide with one of the busiest periods for Scottish airports. Edinburgh is expected to handle almost one million passengers this month.
An airport spokesman said: "We are working closely with the UK Border Force to understand if there will be an impact to the service at Edinburgh."
Hampden Park, in Glasgow, is to host two Olympic men's football matches – Honduras v Morocco and Spain v Japan – on the day of the strike.
The Edinburgh Festival Fringe is due to begin on August 3. Liz Cameron, chief executive of the Scottish Chamber of Commerce, said: "Both events will contribute enormously to attracting tourists to Scotland and money being spent in retail, tourism and entertainment, which will maintain jobs in those fields.
"At a time when we have a world-class opportunity to showcase what Scotland and the rest of the UK has to offer to tourists and businesses, this is irresponsible action that cannot possibly be of benefit to Scotland's economy."
Last night, Labour accused the Home Secretary of giving MPs a "selective account" about when she knew G4S was having problems with recruitment.
Mrs May had admitted the Government and Games organisers Locog knew the firm could fail to meet its contract as early as June 27, two weeks before MPs were told of the need for the army.
Shadow home secretary Yvette Cooper said: "Why has Theresa May waited until now to admit the Home Office was, in fact, warned about this two weeks earlier?"
l Former prime minister Gordon Brown will attend the opening ceremony of the Games a week today, despite reports he would not be present. He will also attend other events having won tickets through the public lottery system.
Contextual targeting label: