The easiest option to view Jupyter Notebooks in Confluence is by using this method.
It's also very secure and fast as because notebooks are saved as attachments in parent pages.
Here is step by step guide to use this method.
Create a page and publish it
First you need to create a page and publish it as it is not possible to upload attachments in draft pages.
Please also choose title that is long and descriptive enough as it can be important while searching notebooks.
Select 'Jupyter/IPython Notebooks from files' in Macro browser
Now open Macro editing interface by clicking edit icon. You should see following dialog.
Here you can upload your .ipynb files
. They will be uploaded as page attachments.
Here is rendering part which uses sample.ipynb file available as attachment in this page.
|Nbviewer from file|