uritools
URI parsing, classification and composition
What it is and what it does
uritools is a Python library that replaces urllib.parse with RFC 3986 compliant URI handling. It provides functions to parse URIs into components (scheme, authority, path, query, fragment), compose URIs from individual parts, resolve relative references, and classify URI forms. The module addresses urllib.parse's known non-compliance with RFC 3986 by offering fully standards-compliant alternatives for the most common URI operations.
The package has no external runtime dependencies and installs as a pure Python wheel. It is designed for developers who need strict RFC 3986 compliance—particularly when parsing URIs from untrusted sources, building URI-heavy applications, or integrating with systems that enforce standards-based URI handling. The library includes convenience methods like getport() and getquerydict() to extract specific URI components without manual parsing.
Use it for:
- Parse and validate URIs from external APIs or user input with RFC 3986 compliance.
- Compose URIs programmatically from scheme, host, port, path, and query parameters.
- Resolve relative URI references against a base URI for link normalization.
- Extract and manipulate individual URI components (authority, port, query dict) safely.
- Replace urllib.parse in projects requiring strict standards compliance.
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
Parses, validates, and composes URIs and URI references according to RFC 3986, providing RFC-compliant alternatives to Python's urllib.parse module.
Yes. uritools is actively maintained, has no dependencies, installs easily, carries no known vulnerabilities, and solves a real problem for developers who need RFC 3986 compliance. Install it if you parse URIs from external sources or need standards-strict URI handling; skip it if urllib.parse's quirks are acceptable for your use case.
Install
uritools on PyPI
pip
pip install uritoolsuv
uv add uritoolspoetry
poetry add uritoolsInstalling uritools
Before you install
Low friction install with no runtime dependencies. Actively maintained as of 2026-08-01, marked Production/Stable, and supports current Python versions.
License in practice
MIT license (permissive) allows use in both open-source and proprietary projects with minimal restrictions.
Quickstart
pip install uritools
from uritools import uricompose, urisplit
uri = uricompose(scheme='foo', host='example.com', port=8042, path='/over/there', query={'name': 'ferret'})
parts = urisplit(uri)
print(parts.scheme, parts.authority, parts.getport(default=80))
Requires Python 3.10 or later.
Package facts
| License | MIT (permissive) |
| Python support | supports the current Python release (>=3.10) |
| Install friction | low — pure-Python wheel |
| Runtime dependencies | none |
| Maintenance | actively maintained — 22 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 12,452,872/month — #1,318 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: uritools-6.1.3-py3-none-any.whl
Tags
More Python Modules packages
Converts domain names between Unicode and…
permissive · top 100 on PyPI
setuptoolsSetuptools is a Python build backend and…
permissive · top 100 on PyPI
PyYAMLPyYAML parses and emits YAML 1.1 data format,…
permissive · top 100 on PyPI
pydanticPydantic validates Python data structures…
permissive · top 100 on PyPI
annotated-typesProvides reusable metadata objects for use with…
permissive · top 100 on PyPI
typing-inspectionProvides runtime tools to inspect and…
permissive · top 100 on PyPI
rfc3986Parses, validates, and normalizes URIs…
permissive · top 1,000 on PyPI
hyperlinkHyperlink provides an immutable, RFC…
permissive · top 1,000 on PyPI
pyuriPyURI parses, constructs, and manipulates URIs…
permissive · top 15,000 on PyPI
rfc3987Provides RFC 3986 and RFC 3987 compliant…
copyleft · top 5,000 on PyPI
arcpGenerate and parse arcp (Archive and Package)…
permissive · top 15,000 on PyPI
rfc3986-validatorValidates URLs and URI references against the…
permissive · top 1,000 on PyPI
lazr.uriParse, manipulate, and generate URIs with a…
copyleft · top 15,000 on PyPI
can-adaParses and manipulates URLs according to the…
permissive · top 15,000 on PyPI
ada-urlParse, validate, and manipulate URLs according…
permissive · top 15,000 on PyPI
prefixcommonsConverts between CURIEs (compact URI…
permissive · top 15,000 on PyPI