A nonprofit that aims to maintain local ownership for newspapers will buy 22 papers in Maine, including The Portland Press Herald and The Sun Journal of Lewiston.

The National Trust for Local News, a nonprofit that was started in 2021, will buy the papers from Masthead Maine, a private company that owns most of the independent media outlets in the state, including five of its six daily papers. Masthead Maine’s owner, Reade Brower, had signaled this year that he was exploring a sale.