Country music star Toby Keith, celebrated in Middle America for his patriotic fervor and songs extolling the pleasures of drinking, has passed away aged 62, a statement on his social media account said Tuesday.

"Toby Keith passed peacefully last night on February 5th surrounded by his family. He fought his fight with grace and courage," a statement posted to Keith's account on X, formerly Twitter, stated.

The Oklahoma-born singer, who was a roughneck in the oil fields of his home state before breaking into country in the 1990s, had been diagnosed with stomach cancer in 2022.

Keith was a controversial figure who often raised eyebrows for the intensity of his nationalist sentiments, with detractors calling him jingoistic.

"Courtesy of the Red, White and Blue (The Angry American)," released in the aftermath of the September 11 attacks, memorably has the line, "We'll put a boot in your ass / It's the American way."

In "The Taliban Song," Keith describes ordinary Afghans praying for US forces to drive out the foreign fighters of the Taliban and Al-Qaeda -- which was led by the Saudi-born Osama bin Laden. In the chorus, Keith sings, "Ride, camel, ride!"

Usually clad in a cowboy hat, he also had a long list of songs exploring the cathartic effects of alcohol including "I Love This Bar," "Whiskey Girl," "Get Drunk and Be Somebody," "Drinks After Work" and "Drunk Americans."

"Beer For My Horses," one of Keith's best-known songs, sings of getting tough on crime and corruption.

He was also known for his feuds and grudges, including against The Chicks lead singer Natalie Maines -- touring with a doctored photo of her and Saddam Hussein after her comments against the US invasion of Iraq.

Keith was the most famous performer at former US president Donald Trump's inauguration in 2017, though he also played at events for Trump's predecessor, Barack Obama.

He frequently performed for US troops overseas, often raising his middle finger in the air in an unsubtle message to foreign adversaries.

Later in 2017 he played a male-only concert in Saudi Arabia to mark a Trump visit there -- an unlikely venue for a star more often seen packing arenas in the US heartland.