Notes produced in court also suggested he had become a fugitive because he was involved with Wikileaks, the organisation that has leaked US state secrets.
Our correspondent in Seoul, Steve Evans, says it is impossible to know how those notes were written - whether under duress or not - and it is not clear whether there is any truth to the allegations.
After a 90-minute trial, the sentence was handed down and Mr Miller was handcuffed and led from the room, AP reports.
The White House has described securing the release of Mr Miller and the two other American citizens detained in North Korea as a "top priority".