NEW YORK — Lil Nas X has taken his horse to the old town road and ridden it to the top of the Billboard charts for 16 weeks, tying a record set by Mariah Carey and Luis Fonsi.

“Old Town Road” logs its 16th week at No. 1 on Billboard’s Hot 100 chart this week, matching the success that Carey and Boyz II Men’s “One Sweet Day” achieved in 1995-1996. Fonsi, Daddy Yankee and Justin Bieber’s “Despacito” accomplished the feat in 2017.

No song has spent more than 16 weeks at No. 1 on the all-genre Hot 100 chart in the 61-year history of the Billboard charts.

The country-rap “Old Town Road” was originally a solo song, but 20-year-old Lil Nas X added Billy Ray Cyrus to the track and it topped the charts, achieving most of its success through audio streaming.

Lil Nas X is looking forward to setting a new Billboard record next week. He posted a video Monday on social media of the “SpongeBob SquarePants” character Squidward Tentacles saying, “Please stream ‘Old Town Road.’”

“Me on the internet this whole week tryna break the billboard record,” he wrote in the caption.

“Old Town Road” initially was in a bit of controversy in March when Billboard removed it from its country charts, deeming it not country enough (it peaked at No. 19 on the country charts). But the drama didn’t hurt the song; it only propelled it.

“This song has been a uniter not a divider,” Cyrus said in a statement Monday. “I’m giving God the glory now for allowing me the gift to be part of such a special song. It’s a unique moment in time where people from all over the world and all walks of life find they have more in common than they do different. It’s a moment we’ve all shared and I’m grateful for it.”

“Old Town Road” appears on Lil Nas X’s debut EP “7,” which peaked at No. 2 on Billboard’s 200 albums chart earlier this month. The EP also features the Top 40 hits “Panini” and “Rodeo” with Cardi B.

”Old Town Road” is also spending its 16th week on top of both the R&B/Hip-Hop and rap songs charts. The song has several versions, including remixes featuring Diplo, Young Thug and Mason Ramsey; Billboard counts the original song and its remix versions as one when calculating chart position, thus helping “Old Town Road” stay on top.

A number of songs have debuted at No. 2 on the Hot 100 chart, unable to push “Old Town Road” out of its top position, including two tunes from Taylor Swift (“You Need to Calm Down,” ‘’ME!”); Ed Sheeran and Bieber’s “I Don’t Care”; and two songs from Shawn Mendes (“If I Can’t Have You,” ‘’Senorita” with Camila Cabello).

Swift’s “Look What You Made Me Do” stopped “Despacito” from reaching a 17th week at No. 1 when the pop smash jumped from No. 77 to No. 1 in 2017. Celine Dion’s “Because You Loved Me” ended Carey and Boyz II Men’s epic run in 1996.