But after an international outcry over the arrest, Saudi Arabia said the woman has been released without charge.
In a statement published Wednesday by the Saudi Center for International Communication, Riyadh said police had questioned the woman for several hours but not charged her. The video had been published without her knowledge, the statement said.
The brief clips, originally posted to the social network Snapchat over the weekend by a popular user named Khulood, showed the woman walking through an ancient fort in Ushayqir, a village in Najd province about 95 miles from Riyadh.
In the video, the woman is wearing a skirt that stops above her knees and a top that shows her midriff; her head is uncovered.
Such an outfit runs afoul of conservative Islamic ideas about women's dress that are prevalent in Saudi Arabia. The country legally requires women to cover themselves while in public by wearing an abaya, a loosefitting cloak. Traditionally, Saudi women are also expected to wear some kind of hijab or head covering, and some opt to cover their face with a niqab.
Although foreigners are usually exempted from such rules and Saudi women often find ways to evade them, many conservative Saudis feel strongly about the dress codes.
Ushayqir appears deserted in the video, but the footage soon spread online and quickly drew criticism — with many Saudis using a hashtag that calls for the woman to face trial.
Some argued that because the woman lived in Saudi Arabia, she should accept its laws. “Just like we call on people to respect the laws of countries they travel to, people must also respect the laws of this country,” Saudi writer Ibrahim al-Munayif wrote on his Twitter account.
But others offered support for the woman, suggesting that her behavior was brave and that prominent foreigners sometimes dress similarly when visiting Saudi Arabia and are exempted from the country's dress codes. Many pointed out that Melania Trump and Ivanka Trump did not wear abayas when they visited the country in May, to little public outcry.
One user crudely superimposed Ivanka Trump's face onto the woman's. “We have solved the problem,” read the tweet, shared nearly 2,000 times.
There had been a number of official calls for an investigation into the video. Saudi newspaper Okaz reported Sunday that local officials had written a letter to the region's governor and police asking them for action against those who made the video. Saudi Arabia's religious police also released a statement on Twitter saying they were aware of the video and were looking into the matter.
Saudi Arabia has some of the world's strictest laws for women. In addition to the restrictions on their dress, adult women need to have the permission of a “male guardian” to do things such as work or travel, and they are prohibited from getting driver's licenses, meaning that, in practice, they cannot drive.
“Saudi Arabia’s continuing obsession with policing women’s clothing choices shows authorities haven’t moved on from the paternalistic and discriminatory mind-set that hampers women’s lives,” said Sarah Leah Whitson, executive director of Human Rights Watch's Middle East and North Africa division. “Saudi Arabia’s purported plans to reshape society and advance women’s rights will never succeed as long as authorities go after women for what they wear.”
Crown Prince Mohammed bin Salman has launched an ambitious plan, Vision 2030, to reform Saudi Arabia's society. Although the program includes some social aspects, such as the promotion of entertainment, there are doubts about whether it will be able to address the entrenched gender inequality.
A poll conducted in 2014 found that 63 percent of Saudis believed that women should wear a niqab, which covers all of the face except the eyes, and just 3 percent thought women not covering their hair were dressed appropriately.
More on WorldViews