16 best Python Binance libraries in 2024

share link

by reegs20 dot icon Updated: Nov 14, 2023

technology logo
technology logo

Guide Kit Guide Kit  

Build wallets, mine coins, integrate with crypto exchanges, automated trading bots, and more using Python Binance libraries. 

Users can trade cryptocurrencies on Binance, which is an online exchange. It supports all of the most widely used cryptocurrencies. Binance provides a cryptocurrency wallet for users to keep their digital currency. Binance Coin (BNB) is a blockchain-based cryptocurrency. 


You can connect to the Binance servers using the Python programming language by using the Python-Binance application programming interface. You can place orders, trade, withdraw funds, and access real-time data from the Binance exchange via the API. You can connect to the Binance servers using Python or many other programming languages by using the Binance API. You can use it to automate your trading. In more detail, Binance features a RESTful API that sends and receives data via HTTP queries. Additionally, a WebSocket is accessible for streaming data, including price quotes and account changes. 


Many Python libraries are available for the Binance API; the most popular option is Python-Binance. Check out the below list to find the best Python Binance libraries for your application: 

binance-trade-bot:  

  • Supports multiple trading strategies, including backtesting and live trading.  
  • Includes a variety of technical indicators and risk management tools.  
  • Provides a user-friendly interface for managing orders and positions.  
Python doticonstar image 7160 doticonVersion:Currentdoticon
License: Strong Copyleft (GPL-3.0)

Automated cryptocurrency trading bot

Support
    Quality
      Security
        License
          Reuse

            binance-trade-botby edeng23

            Python doticon star image 7160 doticonVersion:Currentdoticon License: Strong Copyleft (GPL-3.0)

            Automated cryptocurrency trading bot
            Support
              Quality
                Security
                  License
                    Reuse

                      python-binance:  

                      • Supports all Binance APIs, including spot, margin, and futures.  
                      • Provides a high-performance WebSocket API for real-time data streaming.  
                      • Includes libraries and tools for building custom trading bots and applications.  

                      python-binanceby sammchardy

                      Python doticonstar image 5270 doticonVersion:v1.0.17doticon
                      License: Permissive (MIT)

                      Binance Exchange API python implementation for automated trading

                      Support
                        Quality
                          Security
                            License
                              Reuse

                                python-binanceby sammchardy

                                Python doticon star image 5270 doticonVersion:v1.0.17doticon License: Permissive (MIT)

                                Binance Exchange API python implementation for automated trading
                                Support
                                  Quality
                                    Security
                                      License
                                        Reuse

                                          Binance-volatility-trading-bot:  

                                          • Automatically trades cryptocurrency pairs based on their volatility.  
                                          • Supports multiple trading strategies, including mean reversion and breakout trading.  
                                          • Provides a variety of settings and parameters for customizing the trading bot. 

                                          Binance-volatility-trading-botby CyberPunkMetalHead

                                          Python doticonstar image 3227 doticonVersion:Currentdoticon
                                          License: Permissive (MIT)

                                          This is a fully functioning Binance trading bot that measures the volatility of every coin on Binance and places trades with the highest gaining coins If you like this project consider donating though the Brave browser to allow me to continuously improve the script.

                                          Support
                                            Quality
                                              Security
                                                License
                                                  Reuse

                                                    Binance-volatility-trading-botby CyberPunkMetalHead

                                                    Python doticon star image 3227 doticonVersion:Currentdoticon License: Permissive (MIT)

                                                    This is a fully functioning Binance trading bot that measures the volatility of every coin on Binance and places trades with the highest gaining coins If you like this project consider donating though the Brave browser to allow me to continuously improve the script.
                                                    Support
                                                      Quality
                                                        Security
                                                          License
                                                            Reuse

                                                              binance-trader:  

                                                              • Provides a simple and easy-to-use interface for managing trades on Binance.  
                                                              • Support trading orders, including market orders, stop orders, and limit orders.  
                                                              • Includes a variety of technical indicators and risk management tools.

                                                              binance-traderby yasinkuyu

                                                              Python doticonstar image 2322 doticonVersion:Currentdoticon
                                                              no licences License: No License (null)

                                                              💰 Cryptocurrency Trading Bot for Binance (Experimental)

                                                              Support
                                                                Quality
                                                                  Security
                                                                    License
                                                                      Reuse

                                                                        binance-traderby yasinkuyu

                                                                        Python doticon star image 2322 doticonVersion:Currentdoticonno licences License: No License

                                                                        💰 Cryptocurrency Trading Bot for Binance (Experimental)
                                                                        Support
                                                                          Quality
                                                                            Security
                                                                              License
                                                                                Reuse

                                                                                  Binance-News-Sentiment-Bot:  

                                                                                  • Tracks and analyzes cryptocurrency news and social media sentiment.  
                                                                                  • Provides insights into market sentiment and potential trading opportunities.  
                                                                                  • Helps to automate trading decisions based on news and sentiment analysis.  

                                                                                  Binance-News-Sentiment-Botby CyberPunkMetalHead

                                                                                  Python doticonstar image 1518 doticonVersion:Currentdoticon
                                                                                  License: Permissive (MIT)

                                                                                  This is a fully functioning Binance trading bot that takes into account the news sentiment for the top 100 crypto feeds. If you like this project consider donating though the Brave browser to allow me to continuously improve the script.

                                                                                  Support
                                                                                    Quality
                                                                                      Security
                                                                                        License
                                                                                          Reuse

                                                                                            Binance-News-Sentiment-Botby CyberPunkMetalHead

                                                                                            Python doticon star image 1518 doticonVersion:Currentdoticon License: Permissive (MIT)

                                                                                            This is a fully functioning Binance trading bot that takes into account the news sentiment for the top 100 crypto feeds. If you like this project consider donating though the Brave browser to allow me to continuously improve the script.
                                                                                            Support
                                                                                              Quality
                                                                                                Security
                                                                                                  License
                                                                                                    Reuse

                                                                                                      binance-tutorials:  

                                                                                                      • Provides tutorials and resources for learning how to use Binance and Python programming.  
                                                                                                      • Covers topics such as trading, technical analysis, and bot development.  
                                                                                                      • Includes a variety of code examples and sample projects.  

                                                                                                      binance-tutorialsby hackingthemarkets

                                                                                                      Python doticonstar image 776 doticonVersion:Currentdoticon
                                                                                                      no licences License: No License (null)

                                                                                                      Real-Time Candlestick Charts and Crypto Trading Bot using Binance API and Websockets

                                                                                                      Support
                                                                                                        Quality
                                                                                                          Security
                                                                                                            License
                                                                                                              Reuse

                                                                                                                binance-tutorialsby hackingthemarkets

                                                                                                                Python doticon star image 776 doticonVersion:Currentdoticonno licences License: No License

                                                                                                                Real-Time Candlestick Charts and Crypto Trading Bot using Binance API and Websockets
                                                                                                                Support
                                                                                                                  Quality
                                                                                                                    Security
                                                                                                                      License
                                                                                                                        Reuse

                                                                                                                          unicorn-binance-websocket-api:  

                                                                                                                          • A high-performance WebSocket API for streaming real-time data from Binance.  
                                                                                                                          • Supports all Binance markets, including spot, margin, and futures.  
                                                                                                                          • Provides a variety of features for managing data streams and handling events.  

                                                                                                                          unicorn-binance-websocket-apiby oliver-zehentleitner

                                                                                                                          Python doticonstar image 317 doticonVersion:1.30.0doticon
                                                                                                                          License: Permissive (MIT)

                                                                                                                          An unofficial Python API to use the Binance Websocket API`s (com+testnet, com-margin+testnet, com-isolated_margin+testnet, com-futures+testnet, jersey, us, tr, jex, dex/chain+testnet) in a easy, fast, flexible, robust and fully-featured way.

                                                                                                                          Support
                                                                                                                            Quality
                                                                                                                              Security
                                                                                                                                License
                                                                                                                                  Reuse

                                                                                                                                    unicorn-binance-websocket-apiby oliver-zehentleitner

                                                                                                                                    Python doticon star image 317 doticonVersion:1.30.0doticon License: Permissive (MIT)

                                                                                                                                    An unofficial Python API to use the Binance Websocket API`s (com+testnet, com-margin+testnet, com-isolated_margin+testnet, com-futures+testnet, jersey, us, tr, jex, dex/chain+testnet) in a easy, fast, flexible, robust and fully-featured way.
                                                                                                                                    Support
                                                                                                                                      Quality
                                                                                                                                        Security
                                                                                                                                          License
                                                                                                                                            Reuse

                                                                                                                                              BTB-manager-telegram:  

                                                                                                                                              • A Telegram bot for managing Binance trading bots.  
                                                                                                                                              • Allows users to start, stop, and monitor their trading bots from Telegram.  
                                                                                                                                              • Provides real-time notifications about trading activity and account status.  
                                                                                                                                              Python doticonstar image 312 doticonVersion:v1.2.1doticon
                                                                                                                                              License: Permissive (MIT)

                                                                                                                                              A feature packed but easy-to-use Telegram bot for remotely managing Binance Trade Bot instances

                                                                                                                                              Support
                                                                                                                                                Quality
                                                                                                                                                  Security
                                                                                                                                                    License
                                                                                                                                                      Reuse

                                                                                                                                                        BTB-manager-telegramby lorcalhost

                                                                                                                                                        Python doticon star image 312 doticonVersion:v1.2.1doticon License: Permissive (MIT)

                                                                                                                                                        A feature packed but easy-to-use Telegram bot for remotely managing Binance Trade Bot instances
                                                                                                                                                        Support
                                                                                                                                                          Quality
                                                                                                                                                            Security
                                                                                                                                                              License
                                                                                                                                                                Reuse

                                                                                                                                                                  crypto-bot:  

                                                                                                                                                                  • A comprehensive Python library for building cryptocurrency trading bots.  
                                                                                                                                                                  • Supports all Binance markets, as well as other exchanges and wallets.  
                                                                                                                                                                  • Provides a variety of features for backtesting, live trading, and risk management.  

                                                                                                                                                                  crypto-botby iilunin

                                                                                                                                                                  Python doticonstar image 232 doticonVersion:v0.0.117doticon
                                                                                                                                                                  License: Permissive (Apache-2.0)

                                                                                                                                                                  Binance crypto bot which supports smart entry, trailing stop-losses and take profits, multiple exit targets, One-Cancels-the-Other functionality, UI Interface

                                                                                                                                                                  Support
                                                                                                                                                                    Quality
                                                                                                                                                                      Security
                                                                                                                                                                        License
                                                                                                                                                                          Reuse

                                                                                                                                                                            crypto-botby iilunin

                                                                                                                                                                            Python doticon star image 232 doticonVersion:v0.0.117doticon License: Permissive (Apache-2.0)

                                                                                                                                                                            Binance crypto bot which supports smart entry, trailing stop-losses and take profits, multiple exit targets, One-Cancels-the-Other functionality, UI Interface
                                                                                                                                                                            Support
                                                                                                                                                                              Quality
                                                                                                                                                                                Security
                                                                                                                                                                                  License
                                                                                                                                                                                    Reuse

                                                                                                                                                                                      backtrader-binance-bot:  

                                                                                                                                                                                      • A backtesting framework for Binance trading bots.  
                                                                                                                                                                                      • Supports a variety of trading strategies and technical indicators.  
                                                                                                                                                                                      • Provides a variety of tools for analyzing trading performance and optimizing strategies.  

                                                                                                                                                                                      backtrader-binance-botby rodrigo-brito

                                                                                                                                                                                      Python doticonstar image 254 doticonVersion:Currentdoticon
                                                                                                                                                                                      License: Permissive (MIT)

                                                                                                                                                                                      :money_with_wings: A example of bot using Backtrader to trade Bitcoins in Binance Exchange.

                                                                                                                                                                                      Support
                                                                                                                                                                                        Quality
                                                                                                                                                                                          Security
                                                                                                                                                                                            License
                                                                                                                                                                                              Reuse

                                                                                                                                                                                                backtrader-binance-botby rodrigo-brito

                                                                                                                                                                                                Python doticon star image 254 doticonVersion:Currentdoticon License: Permissive (MIT)

                                                                                                                                                                                                :money_with_wings: A example of bot using Backtrader to trade Bitcoins in Binance Exchange.
                                                                                                                                                                                                Support
                                                                                                                                                                                                  Quality
                                                                                                                                                                                                    Security
                                                                                                                                                                                                      License
                                                                                                                                                                                                        Reuse

                                                                                                                                                                                                          python-binance-chain:  

                                                                                                                                                                                                          • A Python library for interacting with the Binance Smart Chain (BSC).  
                                                                                                                                                                                                          • Supports all BSC APIs, including transactions, accounts, and contracts.  
                                                                                                                                                                                                          • Provides a variety of features for building and deploying BSC applications.  
                                                                                                                                                                                                          Python doticonstar image 281 doticonVersion:Currentdoticon
                                                                                                                                                                                                          License: Permissive (MIT)

                                                                                                                                                                                                          Binance Chain Exchange API python implementation for automated trading

                                                                                                                                                                                                          Support
                                                                                                                                                                                                            Quality
                                                                                                                                                                                                              Security
                                                                                                                                                                                                                License
                                                                                                                                                                                                                  Reuse

                                                                                                                                                                                                                    python-binance-chainby sammchardy

                                                                                                                                                                                                                    Python doticon star image 281 doticonVersion:Currentdoticon License: Permissive (MIT)

                                                                                                                                                                                                                    Binance Chain Exchange API python implementation for automated trading
                                                                                                                                                                                                                    Support
                                                                                                                                                                                                                      Quality
                                                                                                                                                                                                                        Security
                                                                                                                                                                                                                          License
                                                                                                                                                                                                                            Reuse

                                                                                                                                                                                                                              deltabot:  

                                                                                                                                                                                                                              • A cryptocurrency arbitrage trading bot.  
                                                                                                                                                                                                                              • Supports multiple exchanges, including Binance.  
                                                                                                                                                                                                                              • Automatically scans for arbitrage opportunities and executes trades.  

                                                                                                                                                                                                                              deltabotby lukacci

                                                                                                                                                                                                                              Python doticonstar image 137 doticonVersion:Currentdoticon
                                                                                                                                                                                                                              no licences License: No License (null)

                                                                                                                                                                                                                              🚀Combination of useful bots for Binance users. Pump and dump + Binance listing bot. 👍Best profits. Fastest ever.

                                                                                                                                                                                                                              Support
                                                                                                                                                                                                                                Quality
                                                                                                                                                                                                                                  Security
                                                                                                                                                                                                                                    License
                                                                                                                                                                                                                                      Reuse

                                                                                                                                                                                                                                        deltabotby lukacci

                                                                                                                                                                                                                                        Python doticon star image 137 doticonVersion:Currentdoticonno licences License: No License

                                                                                                                                                                                                                                        🚀Combination of useful bots for Binance users. Pump and dump + Binance listing bot. 👍Best profits. Fastest ever.
                                                                                                                                                                                                                                        Support
                                                                                                                                                                                                                                          Quality
                                                                                                                                                                                                                                            Security
                                                                                                                                                                                                                                              License
                                                                                                                                                                                                                                                Reuse

                                                                                                                                                                                                                                                  bscscan-python:  

                                                                                                                                                                                                                                                  • A Python library for interacting with the BscScan API.  
                                                                                                                                                                                                                                                  • Provides access to a variety of data about BSC transactions, accounts, and contracts.  
                                                                                                                                                                                                                                                  • Helps to build custom blockchain applications and tools.  
                                                                                                                                                                                                                                                  Python doticonstar image 269 doticonVersion:2.0.0doticon
                                                                                                                                                                                                                                                  License: Permissive (MIT)

                                                                                                                                                                                                                                                  The most popular asynchronous Python API for BscScan (Binance Smart Chain Explorer), available via PyPI.

                                                                                                                                                                                                                                                  Support
                                                                                                                                                                                                                                                    Quality
                                                                                                                                                                                                                                                      Security
                                                                                                                                                                                                                                                        License
                                                                                                                                                                                                                                                          Reuse

                                                                                                                                                                                                                                                            bscscan-pythonby pcko1

                                                                                                                                                                                                                                                            Python doticon star image 269 doticonVersion:2.0.0doticon License: Permissive (MIT)

                                                                                                                                                                                                                                                            The most popular asynchronous Python API for BscScan (Binance Smart Chain Explorer), available via PyPI.
                                                                                                                                                                                                                                                            Support
                                                                                                                                                                                                                                                              Quality
                                                                                                                                                                                                                                                                Security
                                                                                                                                                                                                                                                                  License
                                                                                                                                                                                                                                                                    Reuse

                                                                                                                                                                                                                                                                      PumpBot:  

                                                                                                                                                                                                                                                                      • A cryptocurrency pump and dump bot.  
                                                                                                                                                                                                                                                                      • Allows users to create and participate in pump and dump schemes.  
                                                                                                                                                                                                                                                                      • Provides a variety of features for managing pump groups and executing trades.  

                                                                                                                                                                                                                                                                      PumpBotby fj317

                                                                                                                                                                                                                                                                      Python doticonstar image 111 doticonVersion:Currentdoticon
                                                                                                                                                                                                                                                                      License: Permissive (BSD-2-Clause)

                                                                                                                                                                                                                                                                      A bot to use in a pump & dump event on Binance.com

                                                                                                                                                                                                                                                                      Support
                                                                                                                                                                                                                                                                        Quality
                                                                                                                                                                                                                                                                          Security
                                                                                                                                                                                                                                                                            License
                                                                                                                                                                                                                                                                              Reuse

                                                                                                                                                                                                                                                                                PumpBotby fj317

                                                                                                                                                                                                                                                                                Python doticon star image 111 doticonVersion:Currentdoticon License: Permissive (BSD-2-Clause)

                                                                                                                                                                                                                                                                                A bot to use in a pump & dump event on Binance.com
                                                                                                                                                                                                                                                                                Support
                                                                                                                                                                                                                                                                                  Quality
                                                                                                                                                                                                                                                                                    Security
                                                                                                                                                                                                                                                                                      License
                                                                                                                                                                                                                                                                                        Reuse

                                                                                                                                                                                                                                                                                          Simple-Binance-Trader:  

                                                                                                                                                                                                                                                                                          • A simple and easy-to-use Python library for trading on Binance.  
                                                                                                                                                                                                                                                                                          • Supports trading orders, including market orders, stop orders, and limit orders.  
                                                                                                                                                                                                                                                                                          • Provides a variety of technical indicators and risk management tools.  
                                                                                                                                                                                                                                                                                          Python doticonstar image 107 doticonVersion:Currentdoticon
                                                                                                                                                                                                                                                                                          no licences License: No License (null)

                                                                                                                                                                                                                                                                                          This is a simple trading bot for the binance exchange.

                                                                                                                                                                                                                                                                                          Support
                                                                                                                                                                                                                                                                                            Quality
                                                                                                                                                                                                                                                                                              Security
                                                                                                                                                                                                                                                                                                License
                                                                                                                                                                                                                                                                                                  Reuse

                                                                                                                                                                                                                                                                                                    Simple-Binance-Traderby EasyAI

                                                                                                                                                                                                                                                                                                    Python doticon star image 107 doticonVersion:Currentdoticonno licences License: No License

                                                                                                                                                                                                                                                                                                    This is a simple trading bot for the binance exchange.
                                                                                                                                                                                                                                                                                                    Support
                                                                                                                                                                                                                                                                                                      Quality
                                                                                                                                                                                                                                                                                                        Security
                                                                                                                                                                                                                                                                                                          License
                                                                                                                                                                                                                                                                                                            Reuse

                                                                                                                                                                                                                                                                                                              binance-bot:  

                                                                                                                                                                                                                                                                                                              • A comprehensive Python library for building cryptocurrency trading bots.  
                                                                                                                                                                                                                                                                                                              • Supports all Binance markets, as well as other exchanges and wallets.  
                                                                                                                                                                                                                                                                                                              • Provides a variety of features for backtesting, live trading, and risk management.  

                                                                                                                                                                                                                                                                                                              binance-botby Kalaborative

                                                                                                                                                                                                                                                                                                              Python doticonstar image 88 doticonVersion:Currentdoticon
                                                                                                                                                                                                                                                                                                              License: Strong Copyleft (GPL-3.0)

                                                                                                                                                                                                                                                                                                              Very simple binance trading Bot using Binance REST API

                                                                                                                                                                                                                                                                                                              Support
                                                                                                                                                                                                                                                                                                                Quality
                                                                                                                                                                                                                                                                                                                  Security
                                                                                                                                                                                                                                                                                                                    License
                                                                                                                                                                                                                                                                                                                      Reuse

                                                                                                                                                                                                                                                                                                                        binance-botby Kalaborative

                                                                                                                                                                                                                                                                                                                        Python doticon star image 88 doticonVersion:Currentdoticon License: Strong Copyleft (GPL-3.0)

                                                                                                                                                                                                                                                                                                                        Very simple binance trading Bot using Binance REST API
                                                                                                                                                                                                                                                                                                                        Support
                                                                                                                                                                                                                                                                                                                          Quality
                                                                                                                                                                                                                                                                                                                            Security
                                                                                                                                                                                                                                                                                                                              License
                                                                                                                                                                                                                                                                                                                                Reuse

                                                                                                                                                                                                                                                                                                                                  FAQ  

                                                                                                                                                                                                                                                                                                                                  1. What kind of trading strategies can I test using crypto-bot?  

                                                                                                                                                                                                                                                                                                                                  Crypto-bot supports a wide variety of trading strategies. These include mean reversion, breakout, trend following, arbitrage, and market making. Crypto-bot also supports custom trading strategies, which you can implement using Python code.  

                                                                                                                                                                                                                                                                                                                                    

                                                                                                                                                                                                                                                                                                                                  2. How does Binance-News-Sentiment-Bot categorize the output by coin?   

                                                                                                                                                                                                                                                                                                                                  The Binance-News-Sentiment-Bot categorizes its output by coin. It assigns a sentiment score to each coin. It calculates the sentiment score by analyzing news and social media data for each coin. The higher the sentiment score, the more positive the market sentiment is for that coin.  

                                                                                                                                                                                                                                                                                                                                  The Binance-News-Sentiment-Bot also provides a sentiment trend for each coin. This shows how the sentiment for that coin has changed over time.  

                                                                                                                                                                                                                                                                                                                                    

                                                                                                                                                                                                                                                                                                                                  3. What kind of streams does unicorn-binance-websocket-api support?  

                                                                                                                                                                                                                                                                                                                                  The unicorn-binance-websocket-api supports market data streams, account data streams, and user data streams. The unicorn-binance-websocket-api also supports custom streams, which you can create using Python code.  

                                                                                                                                                                                                                                                                                                                                    

                                                                                                                                                                                                                                                                                                                                  4. How do backtrader-binance-bot backtest strategies on historical data?     

                                                                                                                                                                                                                                                                                                                                  The backtrader-binance-bot backtests strategies on historical data by simulating the trading environment. It does this by loading historical data for the desired coin. It then executes the trading strategy on the data. The backtrader-binance-bot then reports on the performance of the trading strategy. This includes metrics such as profit and loss, win rate, and drawdown.  

                                                                                                                                                                                                                                                                                                                                    

                                                                                                                                                                                                                                                                                                                                  5. How does crypto-bot handle stop loss?     

                                                                                                                                                                                                                                                                                                                                  Crypto-bot handles stop loss by placing a stop loss order on each trade. A stop loss order is an order to sell an asset at a certain price in order to limit losses.  

                                                                                                                                                                                                                                                                                                                                  Crypto-bot provides a number of different ways to set stop loss orders. For example, you can set a stop loss order at a certain percentage below the entry price or at a certain price level. Crypto-bot also allows you to trail your stop loss orders. This means that the stop loss order will be automatically moved up as the asset price moves up. This can help to lock in profits and reduce losses. 

                                                                                                                                                                                                                                                                                                                                  See similar Kits and Libraries