When heat waves hit, millions of air conditioners switch on at once, straining the electric grid and raising the risk of blackouts and higher power bills. Utilities often ask customers to turn up their thermostats, but “those strategies can be hard to rely on because they don’t know exactly how consumers are going to behave,” said Kevin Brehm, a manager at RMI, a nonprofit that researches energy systems.

Now, a pilot program in New York City is testing a different approach: plug-in batteries that let renters run window AC units without pulling power from the grid during the most stressed hours. The devices, about the size of a microwave, charge when electricity demand is low and then supply power to the AC for a few hours when demand spikes.

“It’s basically a souped-up version of the power bank that you would use to charge your phone when you go out,” said Andrew Wang, the chief executive officer of Every Electric, the company behind the pilot. The program has partnered with Con Edison, the city’s energy company.

The pilot, which is expanding to more than 1,000 homes this summer, is part of Con Edison’s demand response programs, which pay customers to reduce or shift electricity use. Participants can earn cash rebates roughly equivalent to a month’s electric bill, according to the company. Bianca Pasternack, a New York City renter enrolled in the program, said she received a $100 gift card at the end of the last season. “I can’t put solar panels on my roof,” Pasternack said. “This is at least something that’s accessible and easy. It was very set-it-and-forget-it.”

Brehm explained that during heat events, utilities often turn to backup power plants that are less efficient and more polluting, raising costs and emissions. Over time, those cost spikes can push utilities to build more fossil-fuel plants, with expenses passed to consumers. “There’s a question of emissions, and then there’s also a really important question around affordability,” Brehm said.

The Every Electric battery plugs into the AC unit and then into a wall outlet. A smartphone app detects when demand is low, charging the battery during off-peak hours and using it to power the AC during peak times, typically from 1 to 4 p.m. or 4 to 8 p.m. in the hottest months. The system does not send power back to the grid; instead it reduces demand by using stored battery power.

Virtual power plants — networks of thousands of small, distributed energy devices such as home batteries or smart appliances — are an expanding approach. California, for example, is building one of the world’s largest programs, paying hundreds of thousands of participants to send stored energy back to the grid during extreme climate events. Most of those programs, however, are limited to homeowners with solar panels, making Every Electric’s renter-friendly design notable.

Con Edison said batteries can help reduce peak demand, support renewable energy and lessen the need for new infrastructure.

Every Electric’s pilot grew from about 200 kilowatts of flexible capacity last year to roughly 2 megawatts this summer and, Wang said, the company is looking to expand to other cities. By comparison, California’s virtual power plant program exceeds 200 megawatts.

Brehm said systems like this could meaningfully reduce grid strain if they reach enough households. “It’s a matter of how we’re able to get to that scale,” he said, adding that Every Electric’s installation process is plug-and-play and does not require a ton of permissions.