python programmatically convert py file to ipynb code example Example: convert jupyter notebook to python cmd line jupyter nbconvert --to script [YOUR_NOTEBOOK].ipynb