NEWARK, N.J. — Patrik Elias, the New Jersey Devils' all-time leading scorer, is retiring after a career that spanned almost two decades and included two Stanley Cup titles.

The 40-year-old native of the Czech Republic announced his retirement in a statement Friday. He has not played this season.

Elias played all of his 18 NHL seasons with the Devils, becoming the team's franchise leader in goals (408), assists (617) and points (1,025). He ranks third in games played with 1,240, behind Ken Daneyko (1,283) and Martin Brodeur (1,259). He also is the Devils' single-season leader in points, scoring 96 in 2000-01, when he was named to the NHL's First All-Star Team at left wing.

A four-time All-Star, Elias is the club's all-time playoff leader with 45 goals, 80 assists and 125 points, 21 power-play goals and six game-winning goals. On Jan. 17, 2009, he scored his 702nd career point, surpassing John MacLean to become the franchise's all-time leading scorer. His 16 career overtime goals rank second in NHL history.

The Devils plan to retire his No. 26 at a home game next season.

"After 18 seasons, I am pleased to announce that I will be retiring from the National Hockey League, having played my last game with the New Jersey Devils," Elias said. "For the past few months, I have weighed this decision both physically and mentally. I am happy to say this provides me and my family with closure.

"I came here 22 years ago to play hockey — to do what I loved since I was 5 years old," he added. "I was able to play with great teammates, embrace the camaraderie and team spirit of being a Devil, and bring home a Stanley Cup on two occasions."

Taken in the second round in the 1994 draft, Elias helped the Devils win Stanley Cups in 2000 and 2003. He also appeared in Cup Finals in 2001 and 2012, and four Eastern Conference titles.

Elias made his NHL debut on Dec. 7, 1995, against Toronto, his only appearance that season. He skated in 17 games the following season and joined the team full-time in 1997-98, when he scored 37 points (18g-19a) in 74 games.

Elias represented the Czech Republic nine times in international play, including four Winter Olympics, four World Championships and the 2004 World Cup of Hockey. In Olympic play, Elias captained the 2010 squad and was a member of the 2006 bronze medal-winning team.

In his final NHL game, on April 9, Elias scored a goal, recorded two assists and was named the first star of the game in a 5-1 win over the Maple Leafs.

"Patrik Elias helped to create the foundation for what it means, and what it takes, to be a part of the New Jersey Devils organization," said Josh Harris, managing partner of the Devils and Prudential Center.