It’s always funny to hear how audiences, in 1903, reacted to the outrageous final shot of Edwin S. Porter’s eight-minute film “The Great Train Robbery.” The leader of the film’s outlaw gang, Bronco Billy Anderson, points a gun right at the camera — at the audience — and shoots. People who first saw that thought a gun was actually being fired at them, and so they scrambled to get out of the way. How quaint! But when you experience “Carne y Arena,” the extraordinary six-and-a-half-minute virtual-reality installation that Alejandro G. Iñárritu’ is presenting at the Cannes Film Festival (an earlier version was mounted in Los Angeles), you may find yourself having a similar reaction.

It’s pre-dawn, and you’re alone, in the middle of the scrubby vastness of the Sonoran Desert, and when I say in the middle of that’s not a figure of speech. You’re there, staring out at the gray horizon, surrounded by vistas of sand and shrub brush that stretch in every direction. You can turn whichever way you want, and, more startlingly, you can walk wherever you want, this way or that way. If you were really in the desert, by yourself, with just enough pre-dawn light to glimpse the barren landscape around you, you might be a little frightened, and within 10 seconds I realized the emotion I was feeling was a palpable anxiety. What was going to happen in this desolate wilderness?

Here’s what happens. From a great distance, a ragged group of people begin to emerge and walk toward you. They are immigrants making a trek toward the border. Just as you’ve grown used to their presence (you can walk toward them, or circle around them, or — as you may choose to do — walk right along with them), a helicopter appears in the sky, shining its spotlight downward, and as it flies closer and closer, the light becomes blinding, the sound overwhelming, and you find yourself doing something that’s utterly instinctual: You duck. You try to get out of the way. The threat is that physical, that scary, that real. Just like that, you’ve become part of the audience cowering to avoid being shot at in “The Great Train Robbery.”

For more than 25 years, we’ve been hearing about virtual reality, especially at the movies — it was there in Paul Verhoven’s “Total Recall” (1990), in schlock like “The Lawnmower Man” (1992) and “Brainscan” (1994) and, strikingly and enticingly, in Kathryn Bigelow’s “Strange Days” (1995). It was there, most recently, in “Assassin’s Creed.” Yet I always suspected it was an idea whose fulfillment would turn out to be more virtual than real. “Carne y Arena” demonstrates that the VR revolution — the immersive, big-wow, I can’t believe what I’m seeing one — is here, and that it’s an experience that has the potential, like movies, to mutate into a major entertainment and popular art form.

But that may take a long time. Giving yourself over to Iñárritu’s technically extraordinary, surprisingly humane experiment is an event so novel that it’s a little like being at a nickelodeon 100 years ago. It’s the first virtual-reality installation to truly deliver on the promise of it all, so it’s not the culmination of something. It’s more like the start of something. It’s square one of a new experiential paradigm.

It’s also ingeniously done, staged by a supremely soulful filmmaker who made the wise choice to dazzle us not just with new technology but with a genuine fiction we live inside, for 390 seconds, until it takes up residence in our imaginations. The premise of “Carne y Arena,” to put it bluntly, is that the very sort of middle-class Americans and Europeans who have the luxury of going to a museum will experience the harshness of a border crossing that gets stopped in its tracks. In conjunction with that helicopter, a police Humvee pulls up (it’s huge!), its lights flashing, and the guards jump out and start to yell and point their machine guns. It’s the sort of scene you’ve seen in movies ten thousand times, only now you’re in the hair-trigger thick of it, surrounded by life-size cops shouting “On the ground!” And so, along with the bedraggled people you’re walking with, you can’t help but crouch down. It’s a little like the 1961 Milgram experiment: You do what you’re told.

Morally, it’s a complex experience — I felt a primal empathetic connection to the immigrants, and I also never felt more like a privileged white person who had never known an experience like this. If you try to push into their bodies, you’ll see (literally) their beating hearts, and that might be a bit much: magical realism meets Hallmark.

Yet at “Carne y Arena,” the title of which translates as “Flesh and Sand,” you’re a wide-eyed child again, wowed by the dawn of a medium so new it seems supernatural. At Cannes, the installation is a 15-minute drive from the festival, set up in an airplane hangar. You enter the VR space by yourself, after passing through a metal holding cell filled with the discarded shoes and clothes of actual immigrants who never made it across, and you remove your own shoes and socks. An alarm sounds, signaling you to enter the arena, which is about 60 feet wide, and you’re barefoot on rough cool sand, which is the one piece of physical reality. Two assistants strap on your Oculus Rift headset (very small and simple), which is wired to the ceiling, along with a backpack, and then…you’re off. In the desert. It’s a trick, a ride, an adventure, a story, a nightmare, a lived-in diversion, a sensory experience touched with the compassion of art.

The wonder, in part, comes from having zero idea of how the technology works, not any more than a three-year-old knows about how an airplane flies. How is it that I can walk anywhere, as close to or as far from anything I choose ? The experience is so suggestive that at one point I felt like I could feel the wind blow. At another I thought, “Thank God there’s no one here with a chainsaw.”

“Carne y Arena” was clearly made to express a defining issue of our time: the dehumanization (through demagoguery) of immigrants from Mexico and Central America. The installation isn’t “political,” yet its existence makes a resounding political statement, and it is this: Wherever you stand on the issues of illegal immigration, the people risking their lives to cross the border are human beings, so know their experience. Live it in your heart. Mostly, though, we’re seeing the dramatic embryo of a new form for a new century. To my surprise, when my headset was taken off, I wiped away a tear.