The 70-kilometre fence is a precautionary measure and expected to be completed in the autumn.
“The fence and our increased efforts to hunt wild boar will break the chain of infection so there is less risk of African swine fever spreading to Denmark,” Environment and Food Minister Jakob Ellemann-Jensen said.
There are “11 billion good reasons to do everything we can to prevent African swine fever reaching Denmark,” he added, in reference an estimated potential cost to Denmark of managing an outbreak.
The virus is not harmful to humans but causes haemorrhagic fever in pigs and wild boar that almost always ends in death within days.
It was first spotted in Poland in 2014 when infected wild boar entered from neighbouring Belarus.
Belgium reported its first case in September near the borders with Luxembourg and France, prompting it to carry out a preventive pig slaughter and set up an exclusion zone.
No cases have been reported in Germany.
The Danish wild boar fence has previously received criticism from environmental organisations, who have decried it as ineffective and of greater symbolic than practical effect.
A farmers’ association representative said that the fence was one of a number of measures that would provide reassurance for agricultural workers.
“This is part an insurance policy against African swine flu. You would also insure your house against fire, even though it will probably never burn down,” Mogens Dall of the LandboSyd association told Ritzau.
Denmark is one of Europe's main pork exporters, raising 28 million pigs per year across some 5,000 farms.
Pork accounts for five percent of Danish exports, or 30 billion kroner (four billion euros) in 2016.
In France, the army was in early January called in to help hunters cull thousands of wild boar near the Belgian border. A fence is also in the process of being raised.