NEW YORK — Allstate will start insuring drivers who pick up passengers through ride-hailing apps like Uber and Lyft.

The insurer said Wednesday that the Ride for Hire policy will cost $15 to $20 a year on average and will provide coverage for drivers who get into accidents while they are on the way to pick up new fares.

It said it can also help them deal with gaps in coverage between their own auto insurance and policies offered by the ride-hailing companies.

Allstate Corp. will offer Ride for Hire coverage in Colorado, Illinois, Texas and Virginia in 2015 and said it plans to start offering the coverage in other major markets in 2016. Companies including Farmers, Geico, and USAA also started offering ride-sharing insurance in a few states earlier this year.

Ride-hailing smartphone apps like Uber, Lyft and Summon can be used to book a ride from a nearby driver. The drivers don’t work for the companies directly, however. Some work for car services while others are using their personal vehicles to make extra cash.

On Monday, the Portland, Maine, City Council unanimously approved a temporary agreement that allows Uber to keep operating in the city until a full set of rules are adopted.

The issue of how the drivers are insured is complex and has been contentious at times.

Uber and Lyft both provide insurance for drivers while they are carrying passengers, and they offer varying levels of coverage for drivers who have turned on their app, meaning they are available to give rides, and for drivers who are on their way to pick up a passenger. Drivers are also required to keep a personal auto insurance policy. However Allstate said insurance from ride-hailing app companies sometimes has a higher deductible than a drivers’ personal auto policy.

Last month Uber temporarily pulled out of Kansas in a dispute over insurance coverage and background checks for drivers. Uber also suspended operations in Portland, Oregon, for several months during a dispute over the same issues and has fought against similar laws in other states.