¿Odias los anuncios? Ir Sin publicidad Hoy

Bencode Encoder / Decoder

DatosDesarrollador
ANUNCIO PUBLICITARIO · ¿ELIMINAR?

O
ANUNCIO PUBLICITARIO · ¿ELIMINAR?

Guía

Bencode Encoder / Decoder

Bencode Encoder / Decoder

Encode JSON to Bencode format or decode Bencode back to JSON instantly. Bencode is the serialisation format used by BitTorrent for .torrent files and the DHT protocol. Paste Bencode input to decode it into readable JSON, or paste JSON to encode it into compact Bencode — all client-side with no data transmitted.

Cómo utilizar

Select your direction (Bencode → JSON or JSON → Bencode), paste your input, and the result appears instantly. Use the built-in example to see a real .torrent file structure decoded into JSON.

Características

  • Conversión bidireccional – Bencode to JSON and JSON to Bencode
  • Full type support – integers, byte strings, lists, and dictionaries
  • Example preset – real .torrent file structure for reference
  • Real-time output – converts as you type
  • Solo del lado del cliente – sus datos nunca abandonan el navegador

ANUNCIO PUBLICITARIO · ¿ELIMINAR?

Preguntas frecuentes

  1. What is Bencode and why does BitTorrent use it?

    Bencode is a simple serialisation format designed for BitTorrent by Bram Cohen. It encodes four types: byte strings (4:spam), integers (i42e), lists (l...e), and dictionaries (d...e). BitTorrent uses it for .torrent metainfo files and DHT messages because it is unambiguous (no encoding ambiguity like JSON has for numbers), compact, and trivial to parse in any language without a library.

  2. How does Bencode encode different data types?

    Bencode encodes integers as ie (e.g., i42e), byte strings as : (e.g., 4:spam), lists as le, and dictionaries as de where keys must be byte strings in sorted order. Nesting is supported arbitrarily. There is no native boolean or float type — booleans are represented as integers (0/1) and floats are typically stored as strings.

  3. What information is inside a .torrent file?

    A .torrent file is a Bencoded dictionary containing: the announce URL of the tracker, an info dictionary with the torrent name, piece length, SHA-1 hashes of all pieces, and either a single file length or a list of files with paths and lengths. Optional fields include announce-list (backup trackers), creation date, comment, and created-by. Magnet links encode a subset of this as a URI.

  4. Can Bencode handle binary data?

    Yes. Bencode byte strings are raw binary sequences prefixed with their byte length. This is why .torrent files store SHA-1 piece hashes as raw 20-byte binary strings rather than hex. When converting Bencode to JSON, binary strings are typically represented as hex or Base64 since JSON has no native binary type.

¿Quieres eliminar publicidad? Adiós publicidad hoy

Instalar extensiones

Agregue herramientas IO a su navegador favorito para obtener acceso instantáneo y búsquedas más rápidas

añadir Extensión de Chrome añadir Extensión de borde añadir Extensión de Firefox añadir Extensión de Opera

¡El marcador ha llegado!

Marcador es una forma divertida de llevar un registro de tus juegos, todos los datos se almacenan en tu navegador. ¡Próximamente habrá más funciones!

ANUNCIO PUBLICITARIO · ¿ELIMINAR?
ANUNCIO PUBLICITARIO · ¿ELIMINAR?
ANUNCIO PUBLICITARIO · ¿ELIMINAR?

Noticias Aspectos técnicos clave

Involucrarse

Ayúdanos a seguir brindando valiosas herramientas gratuitas

Invítame a un café
ANUNCIO PUBLICITARIO · ¿ELIMINAR?