pdfplumber: Extract Text, Tables, and Objects from PDFs

Summary
pdfplumber is a Python library for inspecting machine-generated PDFs and extracting text, tables, and positioned page objects. It suits developers who need more layout detail and visual debugging than basic text extraction provides.
At a glance
- Language
- Python
- License
- MIT
- Stars
- 10.8k
- Forks
- 928
- Added to OSRepos
- January 24, 2026
- Last analyzed
- October 3, 2026
Use at your own risk
OSRepos shares public repositories for knowledge and discovery only. Any installation, execution, configuration, or use of code from these repositories is the user's own responsibility. Always review the repository, source code, dependencies, licenses, and security implications before running or installing anything. OSRepos is not responsible for issues, damages, or losses resulting from third-party repositories.
Overview
pdfplumber parses PDFs into detailed, positioned objects such as characters, lines, rectangles, curves, and images. Built on pdfminer.six, it adds higher-level text and table extraction tools for documents where layout and object coordinates matter.
It is aimed at Python developers working with machine-generated PDFs. For scanned documents, OCR is needed elsewhere; pdfplumber does not provide OCR or PDF editing and generation.
Key Features
- Inspect page objects and their properties, including character text, font, size, and coordinates.
- Extract page text, words, and searchable text matches with bounding boxes.
- Find and extract tables using graphical lines, text alignment, or explicitly supplied separators.
- Crop and filter pages to focus extraction on specific regions or objects.
- Render pages and overlay detected objects or table boundaries for visual debugging.
- Use a command-line interface to export object data as CSV or JSON, or page text as plain text.
Use Cases
- Data engineers can turn machine-generated reports into structured text or table data for downstream processing.
- Analysts can extract tables from PDFs and tune detection when documents have unusual layouts or weakly defined cell borders.
- Developers investigating extraction errors can inspect object coordinates and visualize page structure.
- Teams processing forms can use its PDF parsing wrappers to access form-field values, though there is no dedicated form API.
Project Facts
- Language: Python
- License: MIT
- Stars: 10.8k
- Forks: 928
- Topics: pdf, pdf-parsing, table-extraction
- Archived: No
Getting Started
Install with pip:
pip install pdfplumber
For usage examples and configuration details, see the README.
Alternatives
- pdfminer.six: pdfminer.six focuses on parsing PDF text and layout details, while pdfplumber adds a higher-level interface for inspecting objects and extracting tables.
- pypdf: pypdf combines text extraction with PDF editing tasks such as merging and splitting, while pdfplumber focuses on layout-aware inspection and extraction.
- Marker: Marker converts PDFs and other documents into Markdown or structured formats, including scanned files, while pdfplumber focuses on inspecting machine-generated PDFs.
Considerations
- Works best with machine-generated PDFs. Scanned PDFs and OCR-derived documents are not its strength, and OCR is not included.
- Parsing is built on pdfminer.six and is slower than PyMuPDF according to the project’s comparison; choose another tool if speed is the priority.
- Table extraction is configurable, but results depend on document layout and may require cropping or tuning settings.
- Text layout extraction is marked experimental, as are some search and text-line features.
- The library exposes image positions and metadata but does not reconstruct image content. It also does not generate or modify PDFs.
Found this useful?
Share it with someone who would like pdfplumber.
Comparisons
Source repository
Open the original repository on GitHub.
29 counted GitHub visits
Related repositories
Similar repositories that may be relevant next.

omnigent: Orchestrate AI Coding Agents Across Harnesses
October 5, 2026
Omnigent provides a shared orchestration layer for AI coding agents, with policies, sandboxing, and team collaboration. It suits developers who want to combine agent runtimes and access sessions across devices without tying workflows to one harness.

agentevals: Evaluate AI Agents from OpenTelemetry Traces
October 4, 2026
agentevals scores AI agent behavior from existing OpenTelemetry traces, without rerunning agents or making extra model calls. It suits teams building instrumented agents that need local evaluation, golden-set checks, or CI quality gates.

web-design: Create Consistent Web Pages with a Claude Code Skill
October 3, 2026
web-design is a Claude Code skill that turns product briefs, reference URLs, or screenshots into an editable design specification before generating web code. It is suited to developers and designers who want a repeatable, spec-led workflow for building consistent pages.

oomwoo: Build a DIY Robot Vacuum
October 2, 2026
OOMWOO is a planned, hackable robot vacuum built around Raspberry Pi, ROS2 and 2D LiDAR. It is aimed at makers who want to build and customize a locally controlled vacuum, but its hardware and build instructions are still in development.