A Kosovo citizen was sentenced to 20 years in prison on Friday for hacking the personal data of more than 1,000 US military and government personnel and passing the information to Islamic State militants, the US Department of Justice said.

Ardit Ferizi, 20, who was also known as Th3Dir3ctorY, was arrested in Malaysia last year and extradited to the US, where he pleaded guilty in a Virginia federal court in June.

"This case represents the first time we have seen the very real and dangerous national security cyber threat that results from the combination of terrorism and hacking,” Assistant Attorney General Carlin said in a Justice Department statement.

Ferizi hacked the computer server of a US online retailer last year and stole the personal and contact details of about 1,300 US military personnel and federal officials, according to court documents.

He provided the list to British hacker Junaid Hussain, a now-deceased IS recruiter and attack facilitator, the Justice Department said.

In August last year, the statement said, Hussain posted a tweet that contained the information about the military and government personnel and said: "We are in your emails and computer systems, watching and recording your every move, we have your names and addresses."