Hey there, could you help me out with this question? So, when we send Bitcoin from one wallet, like an Electrum wallet, to another Bitcoin address, there's this transaction fee, right? Currently, it's pretty high, and the miners are the ones benefiting from it, got that part. Now, in another scenario, let's say I purchased some bitcoins from a centralized exchange like Binance, and I need to send them to a cold wallet address. Again, there's a transaction fee. But who's raking in this fee: the miners or the CEX platform?
When you send transaction, the miners are been compensated for making it through and in return, the fee is not the only thing they get, they get the block reward + the transaction fees they compile all together in a block, that's how the miners make money from mining bitcoin.
For the centralized exchanges, when you buy bitcoin from them, what you get is not actual bitcoin but numbers, what they give you is data. It's anytime you want to withdraw they give charge you and when they do, it's not for them to use but use as fee to get your bitcoin to your destination address. Buts not all, there is a plot twist on centralized exchanges take fees from their customers. Let me explain;
When you withdraw bitcoin from any centralized exchange, their charges are constant fee even if the mining fee is below 10 sats per vbytes. They will charge you like 0.00038btc(from Binance exchange) which is around $13.5 when what they need to run your transaction might not be more than $3 and when they successfully send your transaction, they keep the rest of the bitcoin with them, you see the plot twist I was telling you.
When the fee get increased again, they increase the withdrawal fees more than what is required for you to run your transaction, that's how centralized exchanges work and milk their customers every blessed day.