Business is booming.

So You Wanted to Get Work Done at the Office?

As managers try to get people back to the office, they struggle with how to restore a sense of community without taking away the focus that often comes with remote work. Meanwhile, some employees are beginning to feel nostalgic for the quiet they had at home, especially since many of the office changes aimed at bringing people back often make it harder to concentrate. (For example, a company has added a climbing wall.)

Research tends to support the squishy feeling that people get more done outside of the office. A study van Stanford of a 16,000 travel agency found that call center agents who worked remotely were 13 percent more productive than their in-person colleagues. Another study of 1,600 professionals found they wrote 8 percent more code with a hybrid schedule compared to full office.

“We’ve freed people from groupthink, we’ve freed them from any exclusion and disrespect, we’ve freed them from micromanaging, deafening and distracting noise,” said Adam Grant, an organizational psychologist at the Wharton School at the University of Pennsylvania. “We literally have a mountain of evidence that if you just let individuals generate ideas, you don’t just get more ideas, you get better ideas.”

But many executives are strongly convinced of the advantages of the office: the possibilities to find mentors, build relationships and brainstorm. Some workers also struggle to be productive at home, especially those with caring responsibilities. Companies therefore go to great lengths to bring peace of mind to the office.

Azeema Batchelor, who works at the law firm of Wiley Rein in Washington, DC, has come to rely on her office’s red-green light system. A sniper-width rod with a dome protrudes from her monitor. When she needs to concentrate, she colors the dome red. During a call, she switches it to yellow. When she’s open to people strolling through her office to chat, a green light beckons them inside.

Ms. Batchelor’s office introduced the colored lighting system earlier this year, when employees came in two or three days a week. The goal is to help them find that balance between productivity and the actually desired stop-and-chat. For example, recently, Mrs. Batchelor’s boss dropped by her office to discuss a workout they were planning. The green light was on.