`fig2plotly(h,'filename',[...],'offline',true,'open',false)` This will result in plotly still trying to open a browser. I have submitted a pull request that fixes this.