Hindu pilgrims walked barefoot on the marble floors of the enormous temple, examining intricate stone carvings of deities etched into the ceilings and images of musical instruments and elephants along the white walls.

As they approached a large gold shrine, many gasped in wonder, having arrived at the place where they believe God resides in the form of sacred images.

The recent opening of Akshardham Mahamandir in Robbinsville, N.J., was a historic moment for Hindus in New Jersey and beyond. The temple, about 15 years in the making, is believed to be the largest in the Western Hemisphere and is expected to draw religious pilgrims and tourists from all over the world.

It has also been clouded in controversy.

Federal law enforcement agents raided the temple construction site in 2021 after workers accused the builders, a prominent Hindu sect with ties to Prime Minister Narendra Modi of India and his ruling party, of forced labor, low wages and poor working conditions. Their lawyers said workers who were Dalit, the lowest rung in India’s caste system, were specifically targeted. A federal criminal investigation is ongoing, as is a wage claim lawsuit.

A spokesman for the temple, Ronak Patel, said the workers came to the United States as volunteers, not as employees, and that volunteerism is a core part of their faith tradition. He said that temple officials were cooperating with the investigation.

In the meantime, the temple, which sits on 180 acres and includes 10,000 statues and spires nearly 200 feet tall, is attracting visitors by the thousands, some there to view the elaborate architecture and design, others for a more spiritual experience.

The Hindu sect Bochasanwasi Akshar Purushottam Swaminarayan Sanstha, known as BAPS, dedicated the temple earlier this month and opened it fully to the public on Wednesday. Pilgrims visiting for the first time were asked to refrain from photography and remain silent, but many giddy devotees whispered to each other, pointed to intricate carvings and some snapped a quick photo.

Dharmik Sheth, born in Vijayawada, India, and raised in Lawrenceville, N.J., visited on a recent afternoon to show his 2-year-old son the temple’s intricately carved reliefs, which depict parables from the Hindu tradition. The new temple, he said, gives him a deeper connection to his roots.

“I have a sense of pride here,” Mr. Sheth said. “I’ve struggled to explain or identify our culture, but this place allows me to do that.”

Santosh Kumar Saini of Jaipur, India, traveled to Robbinsville for a private tour ahead of the opening. The temple, he said, contains the perfect blend of contemporary and traditional style.

“We’ve been to temples in India, but this is one of the biggest we’ve seen,” Mr. Kumar Saini said. “It depicts the real Hinduism.”

One of the first sights visitors see when they approach the temple is a 49-foot gold statue of the sect’s chief deity, Nilkanth Varni, the child-yogi form of Bhagwan Swaminarayan, balanced on one leg in a yogic posture. Though the temple is intended for Hindu worship, organizers wanted to make parts of the building more accessible to non-Hindus. That’s why it includes representations of figures who would be familiar to Muslims, Sikhs and Jains. There are also quotes from Martin Luther King Jr., Abraham Lincoln and Albert Einstein.

For Hindus, the temple is the heart of religious life and where they believe God resides in sacred images of deities, said Yogi Trivedi, a scholar of religion at Columbia University, who served as a volunteer spokesman for the temple during its dedication weekend. Temples, he said, are used for rituals such as the waving of a sacred lamp, communicating with the divine, music and chanting, and the bathing of the sacred image of a deity.

New Jersey has the highest concentration of Hindus of any state, at 3 percent, according to the Pew Research Center. Mr. Trivedi’s research estimates that more than 400,000 Hindus live in New Jersey, and more than 400,000 reside in New York.

BAPS initially hoped to build its temple in East Windsor, N.J. When plans there were rejected, the sect found land in Robbinsville. Construction began in 2015, and it cost about $96 million to build, Mr. Trivedi said.

“For someone who studies and teaches Indian history and Hindu traditions, it’s like winning a World Series,” said Mr. Trivedi. Instead of traveling 8,000 miles away, he said, he can “show students faith, devotion and ritual right in our backyard.”

In Robbinsville, a small community east of Trenton, officials expect the temple to become a major draw for tourists. Mayor David Fried said that a new hotel with about 200 beds will be built to accommodate visitors to the temple, which sits on a former plot of soy farmland.

“When we saw this on paper, we knew it was going to be something,” Mr. Fried said. “Did we expect it to be this? Not in my wildest dreams.”

Even as visitors are making their way to the Robbinsville temple, the treatment of some of the people who worked on its construction is still at issue.

When the temple was raided in 2021, dozens of workers were taken from the construction site. Twenty-one temple workers filed a lawsuit that year, though this month, 12 of them pulled out of the suit. Their lawyer, Aaditya Soni, who is based in Jaipur, said in a text message that the workers believe the facts of the case are false and that they decided to pull out based on religious conviction.

Patricia Kakalec, a lawyer for the workers, says she plans to continue fighting for nine of the laborers who are part of the complaint, but their civil claim is on hold pending a federal investigation.

In addition to the wage issues at the temple, a 17-year-old boy who was volunteering on the construction fell to his death there in 2017. Federal inspectors determined it had been an accident.

The conflict illustrates the complicated lines between U.S. labor laws and the religious concept of selfless volunteerism, which Hindus believe is a key part of their tradition.

“If religious groups are subject to all of the restrictions that apply to other groups, it’ll restrict what they’re able to do,” said Charles Haynes, a senior fellow for religious liberty at the nonprofit Freedom Forum.

“But if there’s real exploitation here,” he added, “BAPS could be on the hook for government intervention.”