Skip to main content
Pre-release

This release is a pre-release and may not be stable for production use.

mariadb-c

mariadb-c is the C extension backend for the mariadb connector. It provides a compiled native module (mariadb_c) that the mariadb package selects automatically when installed alongside it, replacing the pure-Python implementation with a significantly faster alternative.

Relationship to mariadb

Package Description
mariadb Main connector — pure Python, works out of the box
mariadb-c C extension backend — install alongside mariadb for better performance
mariadb-binary Pre-compiled binary wheels with bundled dependencies (recommended for most users)
mariadb-pool Connection pool add-on

When mariadb-c is installed, the mariadb package detects and uses it automatically — no code changes required.

Requirements

  • Python ≥ 3.10
  • MariaDB Connector/C ≥ 3.3 (headers and library must be available at build time)

On Debian/Ubuntu:

sudo apt-get install libmariadb-dev

On RHEL/Fedora:

sudo dnf install mariadb-connector-c-devel

On macOS:

brew install mariadb-connector-c

Installation

Install mariadb together with mariadb-c to get the C-accelerated connector:

pip install mariadb[c]

Or, if you prefer pre-built binary wheels that bundle all native dependencies (no compiler needed):

pip install mariadb mariadb-binary

Usage

No API changes — import mariadb as usual:

import mariadb

conn = mariadb.connect(
    user="alice",
    password="secret",
    host="localhost",
    database="mydb",
)
cursor = conn.cursor()
cursor.execute("SELECT @@version")
print(cursor.fetchone())
conn.close()

To verify which backend is active:

import mariadb

print(mariadb.__version__)       # e.g. "2.0.0rc1-c"
print(mariadb.__version_type__)  # "c"

Links

Metadata

Release files for mariadb-c 2.0.0rc2

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for mariadb-c 2.0.0rc2
File Size Uploaded Provenance
mariadb_c-2.0.0rc2.tar.gz 83.2 kB With provenance Details

Release files / mariadb_c-2.0.0rc2.tar.gz

Download URL mariadb_c-2.0.0rc2.tar.gz
Size 83.2 kB
Tags Source
SHA-256 checksum
How to use checksums
6e1ca3032175e16cb411abda39eb7c1b2a309c166ddde1cc1e11fc3a12e975d2
BLAKE2b-256 checksum
How to use checksums
ad25cde2d66f38246ef3aaf916c8b779cf47211fae896e1b857cd12d666cb9f6
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.7

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Mar 4, 2026.

Transparency log

Security for mariadb-c 2.0.0rc2

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

All 1 file in this release has been uploaded with provenance metadata.

Attestation for mariadb_c-2.0.0rc2.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Mar 4, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page