As the brutality builds and the tragedy unfolds in “Detroit,” you do not find yourself wondering how such things could have happened in the America of 1967.

You find yourself wondering how such things could still be happening in the America of 2017.

Arriving in theaters almost exactly 50 years since the Detroit riots of late July 1967, Kathryn Bigelow’s “Detroit” is a searing, pulse-pounding, shocking and deeply effective dramatic interpretation of events in and around the Algiers Motel, where police tortured, abused and assaulted a dozen “suspects,” murdering three of them.

Like Kathryn Bigelow’s two most recent feature films, “The Hurt Locker” (2008) and “Zero Dark Thirty” (2012), this movie is set against the backdrop of a violent conflict, with many a scene taking place in a war zone.

Only this time the war zone is the fifth largest city in the United States at the time.

Director Bigelow employs her oft-favored, shaky-cam, pseudo-documentary technique to immerse us in the Detroit riots of ’67. In separate episodes, we’re introduced to many of the characters who will become key players in the “Algiers Motel Incident,” as it would come to be known.

• Larry Reed (Algee Smith) is the lead singer for the Dramatics, an R&B group about to go onstage at the Fox Theater and showcase their act for Motown scouts, when the show is canceled and the auditorium is cleared because of the violence erupting just outside.

• Detroit police officer Philip Krauss (Will Poulter) guns down a looter in broad daylight, shooting him in the back — but after Krauss is dressed down by his commanding officer and told he could be facing murder charges, he’s back on the street, in uniform and on duty.

• Melvin Dismukes (John Boyega), working as an armed security guard protecting a small business, hopes he can use his standing as a black authority figure to act as a mediator between law enforcement and some of the locals who are spoiling for a confrontation.

As sections of the city burn, the National Guard is called in, and we see tanks rolling through the streets of Detroit. Shots ring out from all directions. Looters smash storefront windows and run off with electronics and groceries. Detroit police and Michigan state troopers patrol the streets, making arrests and urging people to go home. Rioters throw rocks at firefighters. At times the cops have to duck sniper fire.

Everyone is on edge. It feels like it’s only a matter of time before things go from bad to worse to hellish.

Director Bigelow seamlessly cuts from archival news footage to her cinematographer Barry Ackroyd’s stunning, brilliant and sometimes claustrophobically intense work. By the time the story reaches the Algiers Motel, even if one doesn’t know the history of what transpired there, the sense of impending horror is palpable.

Still wearing his onstage threads, Larry and his friend Fred (Jacob Latimore) take refuge at the Algiers, a rundown motel where guests are still partying by the pool and in their rooms even as shots ring out and flames lap the skyline nearby.

When the National Guard sets up an outpost near the Algiers, a hotel guest named Carl (Jason Mitchell) takes out a starter’s pistol and fires several “shots” into the night, in a dubious effort to prove a point. (The gun is loaded with blanks.) Convinced there’s a sniper holed up in the Algiers, Detroit police and the National Guard storm the hotel, dragging residents out of their rooms as they search for the gunman and/or a weapon.

Officer Krauss takes charge of the interrogation. He and some of his colleagues are incensed when they find two white girls (Kaitlyn Dever and Hannah Murray) in a room with a black man named Greene (Anthony Mackie), whom they immediately assume to be a pimp. Even after Greene provides proof he’s an eight-year veteran of Vietnam just home from the war, cops beat him and threaten to kill him.

As the hours tick by at the Algiers and the cops berate, intimidate and torture a dozen residents lined up against the wall in the lobby, “Detroit” becomes ever more intense, ever smaller in scope. Bigelow eschews the big-picture narrative for an unsettling trip down a rabbit hole. Krauss becomes a dictator, insanely drunk on his own power and hatred, and even the cops and Guardsmen with some misgivings about what is transpiring can’t muster the courage to stop him.

In the third act, “Detroit” shifts gears again and becomes a courtroom drama, with Krauss and his two main henchmen on trial for assault and murder. The film accurately reflects what really happened at that trial, and I’ll leave it at that.

Journalist-screenwriter Mark Boal (Bigelow’s collaborator on “The Hurt Locker” and “Zero Dark Thirty”) does a magnificent job of juggling the multiple storylines and creating fully authentic characters — some flawed, some basically decent, some evil.

“Detroit” is filled with strong performances. John Boyega delivers measured, quietly resonant work. In a relatively small role, Anthony Mackie creates great impact. Will Poulter is an unforgettable villain. Algee Smith deserves best supporting actor consideration for his standout performance as Larry, the singer with the voice that could make angels weep. On the night Larry hoped to make his dreams come, he wound up at the Algiers, in the middle of an American Nightmare.

This is one of the best movies of 2017.

★★★★

Annapurna Pictures presents a film directed by Kathryn Bigelow and written by Mark Boal. Rated R (for strong violence and pervasive language). Running time: 143 minutes. Opens Friday at local theaters.