Skip to content
Manu Sheel Gupta edited this page Apr 7, 2025 · 3 revisions

Welcome to the py-libp2p wiki!

🧠 What is Py-libp2p?

Py-libp2p is a Python implementation of libp2p, the modular peer-to-peer networking stack originally built for IPFS and now widely adopted across decentralized systems. Py-libp2p enables Python applications to communicate over secure, multiplexed, peer-to-peer connections β€” without relying on centralized intermediaries.

This library brings the power of libp2p to Python, opening up peer-to-peer protocols, content addressing, and decentralized service discovery to Python developers.


πŸ”§ Key Features

  • Modular Networking Stack: Use only the protocols you need β€” transport, security, multiplexing, peer discovery, and more.
  • Transport Agnostic: Supports TCP, WebSockets, QUIC, and other pluggable transports.
  • Secure by Default: Encrypted connections via TLS or Noise.
  • Stream Multiplexing: Run multiple logical streams over a single connection with protocols like Mplex.
  • Peer Routing: Integrate DHT-based routing for decentralized peer discovery.
  • Interoperable: Compatible with Go-libp2p and JS-libp2p nodes.

πŸ“¦ Use Cases

  • Building decentralized apps (dApps) and protocols
  • Distributed data transfer (e.g., IPFS/Filecoin integrations)
  • Secure, peer-to-peer communication in edge or IoT environments
  • Custom networking layers for blockchain and Web3 protocols

🚧 Project Status

Py-libp2p is under active development. It is a work-in-progress implementation of the libp2p specification, focused on achieving compatibility and interoperability with the broader libp2p ecosystem.

Contributions, feedback, and issue reports are welcome!


πŸ› οΈ Getting Started

pip install libp2p

See the examples/ directory for sample code to get up and running.


πŸ“š Resources