Speaking to reporters ahead of Saturday’s grand opening of a Turkish mosque in the Washington D.C. area, Erdogan said Turkey's prayers were with the families of Azerbaijani soldiers who lost their lives in two days of fighting with Armenian forces.
The clashes are over the Karabakh region which has been a source of conflict between Armenia and Azerbaijan for years.
"The struggle over Nagorno-Karabakh, which has been occupied [by Armenia] for many years, is a result of the inability of the Minsk Group," Erdogan said, referring to the international organization co-chaired by Russia, the U.S. and France.
The group’s aim is to find a peaceful resolution to the conflict between Azerbaijan and Armenia.
"If the Minsk Group had taken fair and decisive steps over this, we wouldn't have seen this incident happening right now," Erdogan said.
The Minsk Group says it leads the Organization for Security and Co-operation in Europe (OSCE)'s efforts to find a peaceful solution to the dispute between Azerbaijan and Armenia.
Erdogan said that Turkey would support Azerbaijan to the end, adding that he had raised the issue during a two-day nuclear security summit which ended on Friday in the U.S. capital.
"I asked the world to stay sensitive over Armenia's bad intentions – especially over the nuclear weapons," the president said.
Erdogan's remarks came after Azerbaijan said it reclaimed land occupied by Armenia during clashes over Friday and Saturday which saw 12 Azerbaijani soldiers martyred.
Armenia and Azerbaijan fought a six-year war over occupied Karabakh in the early 1980s until a 1994 ceasefire.
In a Twitter post later on Saturday, Turkish Foreign Minister Mevlut Cavusoglu said he had called his Azerbaijani counterpart to also offer his condolences over Baku's soldiers martyred during the latest clashes.