Bitcoin Forum
June 28, 2026, 10:54:53 PM *
News: Latest Bitcoin Core release: 31.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: How many Bitcoins are bought / sold per day - best method to know that?  (Read 166 times)
d5000 (OP)
Legendary
*
Offline

Activity: 4690
Merit: 10840


Decentralization Maximalist


View Profile
June 02, 2026, 06:13:38 PM
Merited by Don Pedro Dinero (3), Mia Chloe (1), SuperBitMan (1)
 #1

To clarify: this is not about the pure transaction volume. It is completely obvious that for every Bitcoin that is bought there is a Bitcoin that was sold.

But on the other hand there is a difference between "buying" and "selling":

- Buy / Purchase: add a buy order to an exchange with it either being executed immediately (market order) or the intention of it to be executed in the short-term. (this is important, because there are fake orders, see below)
- Sale: add a sell order with the same intention.

Sometimes what I want to know how many orders of each kind (Buy/Purchase or Sale) are added each day, with the intention to know the difference between these two numbers (measured in BTC).

The problem is that we'd need to know the real time orderbook for a precise estimation. And data about that seems to be not publicly available normally. In addition, there's the difficulty of fake orders that later are removed or placed very far away for the spot price only to try to incite either optimism or fear ("buy walls" and "sell walls"). If they were removed the same day, it would be easy to spot them if you had access to the real time order book, but some of them are there for longer.

So for an approximation I came up with the following idea in this thread:

- Take the hourly candles of the market data of a major exchange.
- For each candle, take the volume and the direction (green or red).
- If the candle is green, add the volume to the "Purchases", while if the candle is red, add it to the "Sales".

Of course this method is inexact but it becomes more exact if you use more precise candles, i.e. 5-minute or even 1-minute candles. And if you had a candle for each executed order that would be the perfect way. Because if, due to the execution of the order, the price becomes higher, then it is clear that the order was placed with the intention to buy, and vice versa.

I want to ask:

- Has someone tried the same thing and found a better method?
- Is there another flaw I'm not taking into account than the candle imprecision?

███████████████████████████
███████▄████████████▄██████
████████▄████████▄████████
███▀█████▀▄███▄▀█████▀███
█████▀█▀▄██▀▀▀██▄▀█▀█████
███████▄███████████▄███████
███████████████████████████
███████▀███████████▀███████
████▄██▄▀██▄▄▄██▀▄██▄████
████▄████▄▀███▀▄████▄████
██▄███▀▀█▀██████▀█▀███▄███
██▀█▀████████████████▀█▀███
███████████████████████████
.
.Duelbits PREDICT..
█████████████████████████
█████████████████████████
███████████▀▀░░░░▀▀██████
██████████░░▄████▄░░████
█████████░░████████░░████
█████████░░████████░░████
█████████▄▀██████▀▄████
████████▀▀░░░▀▀▀▀░░▄█████
██████▀░░░░██▄▄▄▄████████
████▀░░░░▄███████████████
█████▄▄█████████████████
█████████████████████████
█████████████████████████
.
.WHERE EVERYTHING IS A MARKET..
█████
██
██







██
██
██████
Will Bitcoin hit $200,000
before January 1st 2027?

    No @1.15         Yes @6.00    
█████
██
██







██
██
██████

  CHECK MORE > 
hmbdofficial
Member
**
Offline

Activity: 219
Merit: 67


View Profile
June 02, 2026, 06:33:19 PM
 #2

One thing I still don’t understand clearly how this things works why the selling of bitcoin in large quantities affects the price, because if you look at it someone is selling and another is buying, no bitcoin is lost in the process then why is that when there is a panic sell the price often get affected if for every bitcoin sold is directly linked to a new purchase.
d5000 (OP)
Legendary
*
Offline

Activity: 4690
Merit: 10840


Decentralization Maximalist


View Profile
June 02, 2026, 08:04:34 PM
 #3

One thing I still don’t understand clearly how this things works why the selling of bitcoin in large quantities affects the price, because if you look at it someone is selling and another is buying, no bitcoin is lost in the process then why is that when there is a panic sell the price often get affected if for every bitcoin sold is directly linked to a new purchase.
This is the effect of market orders  (includes also de facto market orders, i.e. limit orders with a limit which already matches an existing order).

Imagine the price is at 70000, and you create a market buy order for 1 BTC. There are only 0.5 BTC at 70000, and the next sell order is 0.5 BTC for 71000.

So with your market order you'll buy both the 70000 order and the 71000 order.

The result of you buy is that the spot price will climb from 70000 to 71000.

Market sell orders have the opposite effect: the price will go down.

Exactly that is what I want to achieve with this thread: to know the number of "buy" and "sell" market orders and defacto market orders.

███████████████████████████
███████▄████████████▄██████
████████▄████████▄████████
███▀█████▀▄███▄▀█████▀███
█████▀█▀▄██▀▀▀██▄▀█▀█████
███████▄███████████▄███████
███████████████████████████
███████▀███████████▀███████
████▄██▄▀██▄▄▄██▀▄██▄████
████▄████▄▀███▀▄████▄████
██▄███▀▀█▀██████▀█▀███▄███
██▀█▀████████████████▀█▀███
███████████████████████████
.
.Duelbits PREDICT..
█████████████████████████
█████████████████████████
███████████▀▀░░░░▀▀██████
██████████░░▄████▄░░████
█████████░░████████░░████
█████████░░████████░░████
█████████▄▀██████▀▄████
████████▀▀░░░▀▀▀▀░░▄█████
██████▀░░░░██▄▄▄▄████████
████▀░░░░▄███████████████
█████▄▄█████████████████
█████████████████████████
█████████████████████████
.
.WHERE EVERYTHING IS A MARKET..
█████
██
██







██
██
██████
Will Bitcoin hit $200,000
before January 1st 2027?

    No @1.15         Yes @6.00    
█████
██
██







██
██
██████

  CHECK MORE > 
Mia Chloe
Legendary
*
Offline

Activity: 1120
Merit: 2236


Contact me for your designs...


View Profile
June 02, 2026, 08:44:46 PM
Merited by d5000 (5), WillyAp (2)
 #4

~snip
Even if you're kinda close to it, I think the biggest flaw is that green candles don't necessarily mean buying volume exceeded selling volume and red candles don't necessarily mean the opposite. Every trade has both a buyer and a seller butt price moves because one side is more aggressive.

Personally I think a better method is to use taker buy vs taker sell volume if the exchange provides it since it gonna show which side initiated the trades.

Another thing is candles only show executed trades not all orders placed. Many buy and sell orders can be  canceled before execution, so candle data cannot accurately measure total buy and sell orders added to the order book.

███████████████████████████
███████▄████████████▄██████
████████▄████████▄████████
███▀█████▀▄███▄▀█████▀███
█████▀█▀▄██▀▀▀██▄▀█▀█████
███████▄███████████▄███████
███████████████████████████
███████▀███████████▀███████
████▄██▄▀██▄▄▄██▀▄██▄████
████▄████▄▀███▀▄████▄████
██▄███▀▀█▀██████▀█▀███▄███
██▀█▀████████████████▀█▀███
███████████████████████████
.
.Duelbits PREDICT..
█████████████████████████
█████████████████████████
███████████▀▀░░░░▀▀██████
██████████░░▄████▄░░████
█████████░░████████░░████
█████████░░████████░░████
█████████▄▀██████▀▄████
████████▀▀░░░▀▀▀▀░░▄█████
██████▀░░░░██▄▄▄▄████████
████▀░░░░▄███████████████
█████▄▄█████████████████
█████████████████████████
█████████████████████████
.
.WHERE EVERYTHING IS A MARKET..
█████
██
██







██
██
██████
Will Bitcoin hit $200,000
before January 1st 2027?

    No @1.15         Yes @6.00    
█████
██
██







██
██
██████

  CHECK MORE > 
d5000 (OP)
Legendary
*
Offline

Activity: 4690
Merit: 10840


Decentralization Maximalist


View Profile
June 02, 2026, 11:00:34 PM
 #5

Personally I think a better method is to use taker buy vs taker sell volume if the exchange provides it since it gonna show which side initiated the trades.
That's a good idea - thank you for the correct term. I also found the metric "Cumulative Volume Delta" which seems to be exactly what I'm searching, but until now I have only found public data for the past.

There is one catch though: Imagine the following situation:

- Trader 1 puts a limit buy order on 70000
- Trader 2 sells via market order into that limit order. Price of last trade: $70000.
- Trader 3 puts a limit buy order on 71000. There are no lower sell orders.
- Trader 4 sells via market order into that limit order. Price of last trade: $71000.

We have now two "taker sales" but the spot price increased $1000.

I wonder how common this situation is on high-volume exchanges - it could however be quite common if we take into account that often orders are placed in a tiny distance (66,777 vs 66,776.99 for example).

We can still say that there is "more interest to buy" in this case, because trader 3 created a higher limit order than trader 1. And no seller placed an order between 70000 and 71000.

The "candle method" I show in the OP takes this into account, while the "Cumulative Volume Delta" and "Maker Volume" method does not. But yeah, the candle method is less precise ...

Another thing is candles only show executed trades not all orders placed. Many buy and sell orders can be  canceled before execution, so candle data cannot accurately measure total buy and sell orders added to the order book.
Yes but that's not that important, because what I want to know is about the really executed orders (i.e. really existing "buys" and "sales"), and there are many fake orders placed all the time.

In reality, to make my definitions of "buy/purchase" and "sale" more precise, perhaps we can use the following definition:

- Buy / Purchase: if the price of an executed order is higher than the previous executed order (even if it was triggered by a market sell order).
- Sale: if the price of an executed order is lower than the previous executed order (even if it was triggered by a market buy order).

███████████████████████████
███████▄████████████▄██████
████████▄████████▄████████
███▀█████▀▄███▄▀█████▀███
█████▀█▀▄██▀▀▀██▄▀█▀█████
███████▄███████████▄███████
███████████████████████████
███████▀███████████▀███████
████▄██▄▀██▄▄▄██▀▄██▄████
████▄████▄▀███▀▄████▄████
██▄███▀▀█▀██████▀█▀███▄███
██▀█▀████████████████▀█▀███
███████████████████████████
.
.Duelbits PREDICT..
█████████████████████████
█████████████████████████
███████████▀▀░░░░▀▀██████
██████████░░▄████▄░░████
█████████░░████████░░████
█████████░░████████░░████
█████████▄▀██████▀▄████
████████▀▀░░░▀▀▀▀░░▄█████
██████▀░░░░██▄▄▄▄████████
████▀░░░░▄███████████████
█████▄▄█████████████████
█████████████████████████
█████████████████████████
.
.WHERE EVERYTHING IS A MARKET..
█████
██
██







██
██
██████
Will Bitcoin hit $200,000
before January 1st 2027?

    No @1.15         Yes @6.00    
█████
██
██







██
██
██████

  CHECK MORE > 
Mia Chloe
Legendary
*
Offline

Activity: 1120
Merit: 2236


Contact me for your designs...


View Profile
June 03, 2026, 04:39:18 AM
Merited by d5000 (2), promise444c5 (1)
 #6

~snip

Well this should make more sense. In your example both trades are technically seller initiated yet the price actually rises because buyers are willing to bid higher.

I think where there is kinda an issue is that once you define a "buy" as any trade executed at a higher price than the previous trade you're no longer measuring order flow but rather price movement. And it's  gonna work if your goal is to estimate bullish vs bearish pressure.

And it's actually similar to how some volume indicators work by assigning volume to up-ticks and down-ticks. It won't tell you who initiated the trade but it does capture if the  executed volume is occurring at increasingly higher or lower prices which seems kinda closer to what you're trying to measure.

███████████████████████████
███████▄████████████▄██████
████████▄████████▄████████
███▀█████▀▄███▄▀█████▀███
█████▀█▀▄██▀▀▀██▄▀█▀█████
███████▄███████████▄███████
███████████████████████████
███████▀███████████▀███████
████▄██▄▀██▄▄▄██▀▄██▄████
████▄████▄▀███▀▄████▄████
██▄███▀▀█▀██████▀█▀███▄███
██▀█▀████████████████▀█▀███
███████████████████████████
.
.Duelbits PREDICT..
█████████████████████████
█████████████████████████
███████████▀▀░░░░▀▀██████
██████████░░▄████▄░░████
█████████░░████████░░████
█████████░░████████░░████
█████████▄▀██████▀▄████
████████▀▀░░░▀▀▀▀░░▄█████
██████▀░░░░██▄▄▄▄████████
████▀░░░░▄███████████████
█████▄▄█████████████████
█████████████████████████
█████████████████████████
.
.WHERE EVERYTHING IS A MARKET..
█████
██
██







██
██
██████
Will Bitcoin hit $200,000
before January 1st 2027?

    No @1.15         Yes @6.00    
█████
██
██







██
██
██████

  CHECK MORE > 
rat03gopoh
Legendary
*
Online Online

Activity: 2716
Merit: 1049


NO KYC Exchanger☝️


View Profile WWW
June 04, 2026, 02:07:47 PM
 #7

I'm slowly trying to understand this request.
If the goal is to capture real trading volume, why not capture it from trade history (per-second, for example)? As far as I know, trade history also has red and green colors to indicate taker activity. If green, takers are buying; if red, takers are selling.

 
 b1exch.to 
  ETH      DAI   
  BTC      LTC   
  USDT     XMR    
.███████████▄▀▄▀
█████████▄█▄▀
███████████
███████▄█▀
█▀█
▄▄▀░░██▄▄
▄▀██▄▀█████▄
██▄▀░▄██████
███████░█████
█░████░█████████
█░█░█░████░█████
█░█░█░██░█████
▀▀▀▄█▄████▀▀▀
d5000 (OP)
Legendary
*
Offline

Activity: 4690
Merit: 10840


Decentralization Maximalist


View Profile
June 11, 2026, 01:16:49 AM
 #8

And it's actually similar to how some volume indicators work by assigning volume to up-ticks and down-ticks.
That's actually what I need, I think. I've not found data on that indicator though. According to Google, I should search for "net volume" or "cumulative volume delta".

I'm slowly trying to understand this request.
As far as I know, trade history also has red and green colors to indicate taker activity. If green, takers are buying; if red, takers are selling.
It seems there are indeed no public charts about that, the best source are the APIs.

With AI help I wrote a python script to get the data from Bitstamp. I paste it below if someone is interested. It prints the trades in the following format:

Code:
Date & Time (UTC)    | Trade ID     | Type | Price      | Amount      
----------------------------------------------------------------------
2026-06-11 01:08:26  | 589192656    | SELL | 61856.21   | 0.00081285  
2026-06-11 01:08:21  | 589192642    | SELL | 61880.27   | 0.01616312  
2026-06-11 01:08:21  | 589192641    | SELL | 61881.00   | 0.00179892  
2026-06-11 01:08:21  | 589192618    | SELL | 61882.39   | 0.00016321  
2026-06-11 01:08:21  | 589192617    | SELL | 61883.09   | 0.00009963

I'll later tweak it a little bit, because it currently seems to not use the uptick/downtick method but the origin of the order which "triggered" the trade (buy or sell market/limit order).

Here for example we have an example for a buy order lower than the previous sell order:

Code:
2026-06-11 00:08:49  | 589175259    | BUY  | 61559.84   | 0.01522248  
2026-06-11 00:08:46  | 589175254    | SELL | 61560.98   | 0.00008207



Here's the script: save it (e.g. gettrades.py) and use it with up to 2 arguments:

1) number of trades to display (default: 100, if you put 0 all fetched trades will be displayed)
2) currency pair (default: btcusd - respect that format so Bitstamp's API recognizes it)


Code:
import datetime
import httpx
import sys

PAIR = "btcusd"
LIMIT = 100

def get_public_trades(currency_pair="btcusd", limit=50):
    """Fetches recent public trades from Bitstamp using HTTP/2 to bypass Cloudflare."""
    # url = f"https://bitstamp.net{currency_pair}/"
    url = f"https://www.bitstamp.net/api/v2/transactions/{currency_pair}/"

    # Precise header set matching a realistic modern browser footprint
    headers = {
        "User-Agent": (
            "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36"
            " (KHTML, like Gecko) Chrome/122.0.0.0 Safari/537.36"
        ),
        "Accept": "application/json, text/plain, */*",
        "Accept-Language": "en-US,en;q=0.9",
        "Referer": "https://www.bitstamp.net/",
        "Origin": "https://www.bitstamp.net",
    }

    params = {"limit": limit}

    # Initialize a client enforcing HTTP/2 protocol architecture
    with httpx.Client(http2=True, headers=headers, timeout=10.0) as client:
        try:
            response = client.get(url, params=params)

            if response.status_code == 403:
                print(
                    "Error 403: Cloudflare protection blocked the request."
                    " Your local IP signature is flagged."
                )
                return []

            response.raise_for_status()
            return response.json()

        except httpx.HTTPStatusError as e:
            print(f"HTTP Error: {e.response.status_code}")
            return []
        except Exception as e:
            print(f"An unexpected connection issue occurred: {e}")
            return []


def format_and_print_trades(trades, print_limit=5000):
    """Formats and prints parsed public trade logs."""
    if not trades or not isinstance(trades, list):
        print("No trade data available to print.")
        return

    print(f"\n--- Printing Last {print_limit} Public Trades ---")
    print(
        f"{'Date & Time (UTC)':<20} | {'Trade ID':<12} | {'Type':<4} |"
        f" {'Price':<10} | {'Amount':<12}"
    )
    print("-" * 70)
    trades_shown = trades if not print_limit else trades[:print_limit]

    for trade in trades_shown:
        timestamp = int(trade.get("date"))
        date_str = datetime.datetime.fromtimestamp(
            timestamp, tz=datetime.timezone.utc
        ).strftime("%Y-%m-%d %H:%M:%S")

        trade_id = trade.get("tid")
        amount = trade.get("amount")
        price = trade.get("price")

        trade_type = "BUY" if trade.get("type") == "0" else "SELL"

        print(
            f"{date_str:<20} | {trade_id:<12} | {trade_type:<4} |"
            f" {price:<10} | {amount:<12}"
        )


if __name__ == "__main__":

    if len(sys.argv) > 1:
       print_limit = int(sys.argv[1])
       if len(sys.argv) > 2:
           pair = sys.argv[2]
       else:
           pair = PAIR
    else:
       print_limit = LIMIT


    print(f"Fetching public trade logs for {pair.upper()} via HTTP/2...")

    trade_history = get_public_trades(currency_pair=pair, limit=50)

    if trade_history:
        print(
            f"Successfully retrieved {len(trade_history)} total transactions."
        )
        format_and_print_trades(trade_history, print_limit=print_limit)

███████████████████████████
███████▄████████████▄██████
████████▄████████▄████████
███▀█████▀▄███▄▀█████▀███
█████▀█▀▄██▀▀▀██▄▀█▀█████
███████▄███████████▄███████
███████████████████████████
███████▀███████████▀███████
████▄██▄▀██▄▄▄██▀▄██▄████
████▄████▄▀███▀▄████▄████
██▄███▀▀█▀██████▀█▀███▄███
██▀█▀████████████████▀█▀███
███████████████████████████
.
.Duelbits PREDICT..
█████████████████████████
█████████████████████████
███████████▀▀░░░░▀▀██████
██████████░░▄████▄░░████
█████████░░████████░░████
█████████░░████████░░████
█████████▄▀██████▀▄████
████████▀▀░░░▀▀▀▀░░▄█████
██████▀░░░░██▄▄▄▄████████
████▀░░░░▄███████████████
█████▄▄█████████████████
█████████████████████████
█████████████████████████
.
.WHERE EVERYTHING IS A MARKET..
█████
██
██







██
██
██████
Will Bitcoin hit $200,000
before January 1st 2027?

    No @1.15         Yes @6.00    
█████
██
██







██
██
██████

  CHECK MORE > 
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!