Hugo convert to json not working


Hugo provides a command convert to json

Its not working for me. as per my understanding it should convert all the mark down files which are present in the content folder to josn format.

but when i am running this command its throwing error.

Failed to set source metadata for file “/Applications/MAMP/htdocs/hugo/quickstart/content/”: json: unsupported type: map[interface {}]interface {}. For more info see For more info see

We are stuck here. Please suggest!


Thanks Bep for your reply. I am able to convert to json now

The only issue which i am facing right now is that when i run the command hugo convert toJSON --output “static” its creating the json of the markdown files which are present in content directory but storing the relative path in static folder

So for example if my hugo resides ( the relative path of content folder ) in /var/www/html/hugo/quickstart/content and i run the command to convert to json the structure which is getting prepared in static folder is /static/var/www/html/hugo/quickstart/content/ ( assuming is present in the contetns folder)

what i want is which contains the json whuld be in static/ folder insted of all the relative path.

I did not found any tutorial or setting for changing this. Kindly suggest!