A Turkish court has lifted a ban on Wikipedia after almost three years. 

Turkey was one of only two countries in the world to entirely block access to the online encyclopedia.

However its constitutional court ruled last month that the ban, in place since April 2017, violated freedom of expression. 

Turkish officials said in 2017 that the ban was needed as Wikipedia had failed to remove content accusing its government of assisting terrorist groups.

Rights groups have regularly criticised the erosion of free speech in Turkey under President Recep Tayyip Erdogan, especially since a failed coup attempt in 2016 triggered a massive crackdown on government critics in the press and beyond.

An Ankara judge gave the order for the ban to be lifted by the telecommunications watchdog after Wikimedia Foundation, the non-profit organisation that hosts the website, had applied to challenge the block.

Users said the website was still inaccessible today though it was expected to be gradually unblocked nationwide. 

The website remains banned in China, the only other country to impose such a restriction.