I’m running n8n locally on Windows and I’m trying to write a file using the Read/Write Files from Disk node.
I configured the node to write a file to this directory: C:\Users\HP\OneDrive\Documents\dev\dev.automation
However, when I execute the workflow, I consistently get the following error: “The file is not writable.”
The input binary data is correctly generated (I can see the file in the Binary tab), but the write operation fails.
Could you please explain what could cause this issue in a local Windows setup and how I can properly configure n8n to allow writing files to a custom directory?
Also, are there any best practices or recommended locations for storing files locally with n8n?
so the issue is likely either permissions on that OneDrive folder (OneDrive can be weird with file locks) or n8n’s security settings blocking that path.
try this -
1. check if n8n has `N8N_RESTRICT_FILE_ACCESS_TO` set in your env vars - it limits where files can be written
2. move your output folder somewhere outside OneDrive like `C:\temp\n8n-files` or use the default n8n data folder
3. make sure the folder exists before writing (n8n wont create parent dirs automatically)
OneDrive folders can have sync locks that block writes - i’d avoid them for automation workflows. lmk if moving to a regular folder fixes it