The Gulf nations Qatar and Bahrain will resume diplomatic ties, the Bahrain News Agency (BNA) and the Qatari Foreign Ministry announced.
The move comes more than two years after an Arab boycott against Qatar was lifted.
Saudi Arabia, the United Arab Emirates, Bahrain and Egypt in January 2021 ended a three-and-a-half-year embargo of Qatar. All but Bahrain then restored travel and trade links.
Bahrain and Qatar each issued official statements announcing the decision to restore relations following a meeting between their delegations at the headquarters of the Gulf Cooperation Council, a six-nation bloc of which both are members, in the Saudi capital of Riyadh.
The end of the blockade
The row that led the quartet to cut all ties with Qatar in 2017 centered around its support for Islamist movements deemed a threat by Arab neighbors as well as its ties with Turkey and Shiite Muslim power Iran.
The four states also had their own individual disagreements with Qatar. The boycott had little impact on Qatar's economy, however. The Gulf country, which hosted the men's football World Cup last year, is one of the world's wealthiest countries owing to its vast natural gas reserves.
Regional heavyweight Saudi Arabia has led efforts to rebuild ties with Qatar and, along with Egypt, reestablished diplomatic relations.
Bahrain, a Sunni Muslim-ruled monarchy with a restive Shiite population, has deep unease over Qatar's relations with Iran. Bahrain also has territorial disputes with Qatar.