A Streamlit web application that allows you to split PDF files by specifying page ranges, with options for password protection and individual part downloads.
- Page Range Splitting: Split PDFs into multiple parts using custom page ranges
- Preview Functionality: View page previews before splitting
- Password Protection: Optionally encrypt output PDFs with passwords
- Flexible Download Options:
- Download all parts as a single ZIP file
- Download individual parts separately
- Custom Naming: Choose from multiple file naming formats
- Summary File: Optional text file with split information
-
Clone the repository:
git clone https://github.com/yourusername/pdf-splitter.git cd pdf-splitter -
Install the required dependencies:
pip install -r requirements.txt
-
Install Poppler (required for PDF to image conversion):
- Windows: Download from poppler-for-windows and add to PATH
- Mac:
brew install poppler - Linux:
sudo apt-get install poppler-utils
-
Run the Streamlit app:
streamlit run app.py
-
In your web browser:
- Upload a PDF file
- Preview pages to verify content
- Define page ranges to split
- Configure advanced options (password protection, naming format)
- Download the results
Edit the following in app.py if needed:
POPPLER_PATH- Set your Poppler binary path if not in system PATH- Default file naming formats
- Preview image sizes
- Python 3.7+
- Streamlit
- PyPDF2
- pdf2image
- Pillow
- poppler-utils (system package)
