No financial terms of the deal were made available.
"I feel like the Rooney family gave me an opportunity to play professional football," Williams said. "It's a great culture here. A great fan base. I take pride in being in Pittsburgh. It's a hard-nosed group of individuals who work here. I feel like the people here are no nonsense, hard-working individuals. They are proud people too. I love this place.
"There have been so many great players that have played for the Steelers, so many great linebackers. Just the legacy here. The history. It's so deep and rich. I really feel like I can relate to the people of Pittsburgh."
Williams, 28, recorded 89 tackles and eight sacks in 2017, both career highs. It was his first year as a full-time starter since 2013.
Relatively unheralded out of Florida State, Williams was an afterthought in the same draft that saw the Steelers use a first-round pick on Jarvis Jones. Whereas Jones lasted just four disappointing NFL seasons, Williams is now signing his second contract extension in Pittsburgh.
According to the team's release, during training camp Williams said he hopes to "die a Pittsburgh Steeler."
He is scheduled to start at the right inside linebacker spot again in 2018.