"The big plan is for the Turks and the Hungarians to be winners together in the 21st century," Orbán said after the signing.
He added that the countries' fraternal and political cooperation was now "the closest in the language of diplomacy".
Hungary was among the "losers" of the last century, but it plans to become a winner in the 21st century, and it is looking for allies in that endeavor, he said.
Erdogan said the friendly ties between Turkiye and Hungary had "deep roots" and both sides aimed to expand those ties, by encouraging corporate investments in each other's countries or joint projects in third countries. He added that the sides aimed to enhance their cooperation in the defense and energy industries.
He welcomed Hungary's participation in the Turkic Council as an observer and wished the country success as it takes the revolving presidency of the Council of the European Union in the second half of 2024.
Orbán said Hungary would do everything in its power to upgrade the customs union between the EU and Turkiye when it held the presidency of the Council. Hungary also supports Turkiye in the matter of visa liberalization, he added.
He noted that bilateral trade had doubled in the past 10 years and that 500 Turkish companies operated in Hungary, while a hundred Hungarian ones were present in Turkiye.
He pointed to the role Turkiye plays in ensuring Hungary's energy security as well as its efforts to address the threat of migration. He also acknowledged Turkiye's role in brokering an agreement on exports of Ukrainian grain across the Black Sea.
Orbán said the sides had agreed on the start of gas purchases from Turkiye.
The Hungarian-Turkish Cultural Year was launched on Monday, marking the centenary of diplomatic ties between the two countries.