Crypto bot

Archived Binance trading bot experiment with a friend — data collection, training, and charts that proved buy-and-hold beat our logic.

This project is finished and archived.

A friend and I wanted to see if we could build a bot to trade crypto. The thinking was simple: the market is volatile, so small frequent trades — if timed well — might add up. We never expected to get rich, and that was never the goal. Making a bit on the side from an automated process we barely had to touch sounded fun enough.

We mapped the Binance trading API and connected with our own Python client, then moved through phases: design, data collection, training, and a deployment step we never reached. In the end we stalled in training for several reasons — not least that financial markets are notoriously hard to predict, let alone encode in an algorithm.

Additional info

Highlights

  • Binance API in Python — design → data → training; deployment never shipped.
  • Self-collected 5-minute interval CSVs (1GB+) when public data was not enough.
  • Visualisation revealed an ‘inverted genius’ loser bot — buy-and-hold won.

Early work was mapping and wiring up the Binance API — that part went quickly. After that we were a bit lost until we realised we needed simulations, which meant accurate historical data we could not find ready-made. So we collected months of crypto ticks ourselves at the finest interval we could (five minutes), ending up with more than a gigabyte of CSV over a few months.

Only then could we refine the algorithm — and it was hard to reason about market behaviour and our own logic. We built visualisations to see when the bot would have bought or sold. Early simulations bled money through constant tiny trades, slowly rather than spectacularly. Then came our magnum opus: an algorithm impressively good at losing — almost buying before every drop and selling before every rise. We joked that inverting it might be a winning strategy; after more runs we concluded we would probably do better buying assets and doing nothing.

Other questions never got solved either, like how much to buy or sell per signal. Eventually the project fizzled out.

We still learnt a lot: data collection, websockets, handling large datasets, tuning algorithms, and data visualisation. It was fun while it lasted.