How to Convert Word Document (.DOCX) & Microsoft Powerpoint PPTX to PDF in Python Using pdfitdown
317 views
Jun 3, 2025
Get the full source code of application here:
View Video Transcript
0:00
uh hello guys uh welcome to this video
0:02
so in this video I will show you a
0:04
Python package which is completely free
0:07
which can actually convert your
0:08
Microsoft PowerPoint and word document
0:11
files to PDF directly so this is
0:14
actually the package the command is
0:16
simple you simply install this package
0:18
PDF it down it also works in the command
0:21
line and in the documentation they have
0:23
mentioned all these files markdown
0:25
PowerPoint word document so these are
0:28
the two popular files you can convert to
0:30
PDF let me show you the simple Python
0:33
script so once you install this as you
0:36
can see we have this word document file
0:38
right here and we got this uh PowerPoint
0:42
file as well so we will try to convert
0:45
this into PDF so what we will do we will
0:49
actually write a simple Python script so
0:52
simply write this and
0:54
uh after that we
0:58
will first of all we need to import this
1:01
module so what we will say from PDF it
1:05
down it contains this function PDF
1:08
conversion and from this we just need to
1:11
import the converter package so in this
1:15
easy way you can import this package
1:17
after that you just need to initialize
1:18
the
1:19
converter it use this converter class
1:23
and after that it contains this function
1:25
which is convert which can actually
1:27
convert
1:30
a word document file or Microsoft
1:33
PowerPoint file
1:36
so here it takes two arguments first
1:39
argument is the actual file path so
1:41
where it is located and the second one
1:43
is the output path
1:46
so I will say docs pdf and here it is
1:51
present in the same directory which is
1:53
sample docs we are providing this file
1:55
right here and same we can do this
2:00
for and here we'll be replacing ppts so
2:04
very four lines of code here you can
2:06
see you just need to call this function
2:09
convert it takes two arguments you
2:11
provide the input file and then you
2:14
provide the output file so now if I run
2:16
this application you will see it will
2:19
create the PDF files on the left hand
2:24
side so both the files have been
2:27
created and this is actually converted
2:30
here you can see the word document file
2:32
successfully converted to multiple pages
2:35
of
2:36
PDF and same goes with the PPT which is
2:40
the PowerPoint file as well you can see
2:42
that multiple slides have been
2:44
successfully exported to PDF so it's a
2:47
really nice package i found out this
2:49
package last week it's a complete free
2:51
package which can actually convert your
2:55
files so definitely install this package
2:58
and start using it and uh it also works
3:01
in the command line as well you simply
3:03
pass just write PDF down and provide the
3:07
input file and then the output file
3:13
so thank you very much for watching this
3:15
video and also check out my website uh
3:18
free media tools.com uh which contains
3:21
thousands of tools
#Programming
#Software