Jupyter Notebook or Google Collab basically supports .ipynb’s, i.e. Python NoteBook. These NoteBooks provide accessibility to the interactive Python code consisting of cell structures.
However, this .ipynb can be directly downloaded into the system or uploaded to your cloud as .ipynb. But if you are looking at how to convert ipynb to PDF, we are here with 4 easy and simple methods to convert ipynb to PDF. Let’s start.
First Method
Open your notebook and under the menu options, look for File, click Download as and look for .pdf via Latex. Remember, there will be two PDF options available, but the final extension of the downloaded file is stated in round braces beside the available options. So here, click for (.pdf) as shown below.
Next, the new tab will be opened in your browser for further processing
If you are downloading pdf for the first time from this option, there will be a lot of packages it will ask you to install, starting from this:
Install all of them, it may take 4-5 mins.
After installation, the terminal will have a success message like this:
Right after the message, your pdf will be downloaded through your notebook tab.
Second Method
Here, we are downloading the pdf with nbconvert.
nbconvert is a command line tool.
Type in your cmd,
pip install nbconvert
This command will check if your system has nbconvert, if it hasn’t, the command will anyways download it.
And the following command will simply convert your ipynb to pdf.
jupyter nbconvert --to pdf filename.ipynb
The file’s location will be the same folder as your notebook.
Note: If you want to convert the notebook to .html, to make it available offline, you can run the same command, just replace pdf with html as,
jupyter nbconvert --to html filename.ipynb
Third Method
Another smart way to convert IPYNB to PDF is to print the notebook and when the printing interface opens, simply save it as PDF.
This is a straightforward and smart way to convert IPYNB to PDF.
Follow the path, File->Print Preview, and preview to file
Now press Ctrl+P.
The printing interface will open up. If the printer is selected already, from the same dropdown, select Save as PDF.
Your PDF is ready.
However, if we compare PDFs with Save as PDF and through the notebook’s functions, both are readable, but one with Jupyter’s functions is slightly more zoomed and like a proper paper with filename and last modified date.
Fourth Method
It’s very easy, open your browser, search google colab, click on the first link, upload your ipynb file, click on the file, then click on print. Click here to directly open google colab.
This method is the easiest one but the problem is that pdf generated will not look similar to the ipynb file.
Thank you, we have successfully completed all methods to convert ipynb to pdf.
Also Read:
- Simple Code to compare Speed of Python, Java, and C++?
- Falling Stars Animation on Python.Hub October 2024
- Most Underrated Database Trick | Life-Saving SQL Command
- Python List Methods
- Top 5 Free HTML Resume Templates in 2024 | With Source Code
- How to See Connected Wi-Fi Passwords in Windows?
- 2023 Merry Christmas using Python Turtle
- 23 AI Tools You Won’t Believe are Free
- Python 3.12.1 is Now Available
- Best Deepfake Apps and Websites You Can Try for Fun
- Amazon launched free Prompt Engineering course: Enroll Now
- 10 GitHub Repositories to Master Machine Learning
- Hello World in 35 Programming Languages
- How to Scrape Data From Any Website with Python?
- Become Job Ready With Free Harvard Computer Science course: Enroll Now
- Free Python Certification course from Alison: Good for Resume
- Download 1000+ Projects, All B.Tech & Programming Notes, Job, Resume & Interview Guide, and More – Get Your Ultimate Programming Bundle!
- Udacity Giving Free Python Course: Here is how to Enroll
- Love Babbar’s Income Revealed
- Top 5 Websites to Learn Programming in 2024
- Python Internship for college students and freshers: Apply Here
- Microsoft Giving Free Python Course in 2023: Enroll Now
- Top 5 Free Python Courses on YouTube in 2024
- Complete Python Roadmap for Beginners in 2024
- New secrets to Earn money with Python in 2024
- Connect with HR Directly – Job Hack
- Google offering free Python course: Enroll Today
- What is an AI Tool?
- Google Internship 2024
- TCS Launched Free Certification Course with Industry Recognized Value