Indeed, Morocco offered the first recognition of an independent United States by any nation in the world, when its progressive Sultan Sidi Muhammad Ibn Adballah wrote to European leaders in December 1777 formally opening Morocco's ports to American ships.